Cut and paste is not to blame... it is the use of word processing software
rather than text editors for manipulating code that is the problem.
Georg: note that plyr does not mix very well with dplyr... try to pick one and
stick with it.
--
Sent from my phone. Please excuse my brevity.
On Jul
My point is that this is highly software-dependent. Certain email programs and
editors are worse than others in inclusion of configuration settings that allow
you to avoid this problem. In general you need to look for "plain text"
options, and some software has "Auto-Correct" options turned on b
R Users
Is there a way to check for modality using the "circular" package in R or
any other package ?
Circular time data.
Jeff
[[alternative HTML version deleted]]
__
R-help@r-project.org mailing list -- To UNSUBSCRIB
This is not a VBA support forum. You need to be studying VBA linkage
requirements and gcc linkage conventions, and neither of these subject areas
are on topic in R-help.
--
Sent from my phone. Please excuse my brevity.
On July 7, 2016 5:27:02 AM PDT, "Mehta, Gaurang"
wrote:
>Hi Team,
>I am tr
Same as with any floating point numeric computation environment... you don't.
There is always uncertainty in any floating point number... it is just larger
in this data than you might be used to.
Once you get to the stage where you want to output values, read up on
?round
?par (digits)
and don
Correction:
?options (not par)
--
Sent from my phone. Please excuse my brevity.
On July 7, 2016 3:26:06 PM PDT, Jeff Newmiller wrote:
>Same as with any floating point numeric computation environment... you
>don't. There is always uncertainty in any floating point number... it
>
1) HTML formatted email does not come through reliably. Please read the Posting
Guide.
2) It is very nearly always necessary to provide a reproducible example when
asking for help on this list to avoid complete failure to communicate.
3) Given the above limitations (meaning I may not be under
function(y) {sum(y>=70)}
--
Sent from my phone. Please excuse my brevity.
On July 9, 2016 1:19:27 PM PDT, Debasish Pai Mazumder wrote:
>I have 4-dimension array x(lat,lon,time,var)
>
>I am using "apply" to calculate over time
> new = apply(x,c(1,2,4),FUN=function(y) {length(which(y>=70))})
>
>Th
I have seen less sensical questions.
It would be nice if the example were a bit more complete (as in it should have
excess degrees of freedom and an answer) and less like a homework problem
(which are off topic here). It would of course also be helpful if the OP were
to conform to the Posting G
The only reason I can imagine for such a "need" is that you have been assigned
homework and there is a no-homework policy on this list. That said, Google came
up with at least one hit when I looked.
You really ought to read the Posting Guide before posting again.
--
Sent from my phone. Please
values of the
>factor-levels and numerical values for the multiplier (f) and the
>offset (o), with p1 and p2 given as names (here: persons) and y given
>as some level of achievement they reach by cooperating.
>
>y = f * ( o - ( p1 - p2 )^2 )
>
>Is that what you meant by "answ
s://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
---
Jeff Newmiller
1) Although it can be as easy as this, when you are dealing with packages the
complications of namespaces may prevent your modified version of the function
now in the global namespace from being used by other functions in the package.
That is, you may have to redefine all of the interrelated fun
I suspect the answer to your question (is there a function...) is almost
certainly yes, but your question is too vague to be sure.
1) Data frames and matrices are different in important ways... it is highly
unlikely that matrices would be appropriate for date data.
2) Do you mean "select recor
No, it refers to confidence level. Refer to your training in statistics for
that definition.
--
Sent from my phone. Please excuse my brevity.
On July 20, 2016 10:01:44 AM PDT, Tom Subia wrote:
>Default level = 0.95.
>Does this mean +/- 0.025 from estimate?
>
> [[alternative HTML version d
Look at the zoo or data.table packages.
--
Sent from my phone. Please excuse my brevity.
On July 20, 2016 1:31:26 PM PDT, lily li wrote:
>Hi R users,
>
>I have a dataframe, where there is a column 'time' represents time
>series
>but is not complete. How to expand the dataframe so this column wi
This is neither the Xpdf support forum nor the Windows Setup Program
Reinvention support group... and you really need to read and follow the Posting
Guide for the R mailing lists.
FWIW I would guess that you need to learn about environment variables and in
particular about the PATH variable. Th
Read the Posting Guide. This will tell you at least two important things:
1) Post using plain text. HTML mangles code.
2) Interfacing R with other languages is off-topic on this list. There are
other lists where such issues are on-topic. Your post is a bit like walking
into a bowling alley and
You are entitled to your opinion, but apparently you have not read the Posting
Guide either.
--
Sent from my phone. Please excuse my brevity.
On July 22, 2016 6:00:19 PM PDT, Dirk Eddelbuettel wrote:
>Jeff Newmiller dcn.davis.ca.us> writes:
>> 2) Interfacing R with other lang
If you complain to the doctor that it hurts when you ram your head into the
wall, (s)he is going to tell you to not so that. What do you expect us to say?
You seem full of misinformation. The apply family functions do not necessarily
speed anything up... they are just more compact than for loop
The mailing list allows very few types of attachments through to limit virus
problems. You need to learn how to convey your problem as a reproducible
sequence of R statements to get clear assistance here. [1]
In this case, you may be confused between the interactive working environment
(variab
An alternative (more compact, not necessarily faster, because apply is still a
for loop inside):
f <- function( m, nx, ny ) {
# redefine the dimensions of my
a <- array( m
, dim = c( ny
, nrow( m ) %/% ny
, ncol( m ) %/% nx )
)
What if it is being used on a platform other than Windows? This problem is more
challenging than you seem to think it is.
I would suggest including a kind of "par" argument to your function that lets
the user change your defaults.
--
Sent from my phone. Please excuse my brevity.
On July 27, 2
This appears to be a question about a contributed package, though you have not
specified which one (so your example code is not reproducible).
Be warned that I have never seen discussion of fuzzy logic on this list, so any
help you get here is likely to be from someone reading the documentation
XLS has nothing to do with XML. The shift from XLS to XLSX/XLSM formats was
where XML was introduced. You might occasionally find mislabelled files that
seem to work anyway, but there is a significant difference inside true XLS
files.
Use a package designed to handle your data format. There ar
;- xmlTreeParse( "nobom.xml" )
--
Sent from my phone. Please excuse my brevity.
On July 28, 2016 8:26:44 AM PDT, "Bos, Roger" wrote:
>Jeff,
>
>Thanks for your suggestions. I mentioned XLS because that is the
>extension the ishares website provides. I have tried
Er, I failed to include the step to write the repaired data to a file...
fnamenobom <- "nobom.xml"
cat( paste( txt, collapse="\n" ), file=fnamenobom )
xmlfile <- xmlTreeParse( fnamenobom )
--
Sent from my phone. Please excuse my brevity.
On July 28, 2016 11:20
What represents the difference when multiple values are present? sd?
--
Sent from my phone. Please excuse my brevity.
On July 28, 2016 1:40:16 PM PDT, Gang Chen wrote:
>With the following data in data.frame:
>
>subject QMemotion yi
> s1 75.1017 neutral -75.928276
> s2 -47.3512
Why not remove it yourself before passing it to those functions?
--
Sent from my phone. Please excuse my brevity.
On July 28, 2016 5:51:47 PM PDT, Jun Shen wrote:
>Dear list,
>
>I write a small function to calculate multiple stats on multiple
>variables
>and export in a format exactly the way I
How did you try to find the answer before posting? Some possibilities might be
go ogling [1] or perusing CRAN to find [2]...
Note that HTML tends to mangle code... please follow the Posting Guide and send
plain text email to this list.
[1] http://bfy.tw/6y3o
[2] https://cran.r-project.org/web/v
Having experienced some frustration myself when I first started with R many
years ago, I can relate to your apparent frustration. However, if you would
like to succeed in using R I strongly recommend learning R and not trying to
write Haskell or Erlang or C or Fortran or any other language when
>> [1] TRUE FALSE TRUE FALSE ## NOT c(T,F,T,F)
>
>I'm not sure what you mean by NOT here. You get the same answer as I
>do, as far as I can see.
>
# valid R
T <- FALSE
# invalid R
TRUE <- FALSE
It is much much safer and clearer to use TRUE/FALSE than T/F. So
c( TRUE, FALSE, TRUE, FALSE ) ma
ncol(data)/nx)
>+ }
>> aggregate.nx.ny.expand.grid(tst.small)
> [,1] [,2] [,3] [,4]
>[1,] 3.5 11.5 19.5 27.5
>[2,] 5.5 13.5 21.5 29.5
>>
>> aggregate.nx.ny.array.apply = function(data,nx=2,ny=2, FUN=mean,...)
>{
>+ a <- array(data, dim = c(ny, nrow( d
3 3412.639 100 c
# 9.191747 21.98528 10.30099 15.9169 158.687 100 a
# 733.246331 936.73359 757.58383 844.2016 2824.557 100 b
On Sat, 30 Jul 2016, Jeff Newmiller wrote:
For the record, the array.apply code can be fixed as below, but then it is
slower than the expand.grid version.
a
ve HTML version deleted]]
__
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, se
o.nz/Reproducibility.html
---
Jeff NewmillerThe . . Go Live...
DCN:Basics: ##.#. ##.#. Live Go...
Live: OO#.. Dead: OO#.. Playing
Research Engineer (Solar/BatteriesO.O#.
R could not find the specified file. Either it is not there or file system
permissions (off topic here) prevented access to the file.
--
Sent from my phone. Please excuse my brevity.
On August 1, 2016 11:30:42 PM PDT, roslinazairimah zakaria
wrote:
>Dear r-usersl,
>
>I don't understand this c
Unfortunately for you, this email list is about R (not C), and while the
Posting Guide indicates that questions discussing how to interface with C
belong in R-devel, that is not a forum for learning C.
On the plus side, the data types and macros you are asking questions about are
highly specif
x <- rnorm( 2, 5, 2.5 )
The requirement for "random" is ill-specified because it omits mention of which
random distribution you want (I assumed normal distribution above).
The requirement for "decimal places" is ill-defined because floating point
numbers are internally represented with mant
I would think knitr package would be useful in this endeavor. And possibly
RStudio
If that doesn't do it, someone here may have a better hint, but solving this
kind of question can require studying both the input (R code) and output
(tikz/LaTeX code). While the R code belongs here, details
This service is normally implemented by the operating system against the
logins, irrespective of the application those users choose to use. It is not
part of R... so you should be looking for OS tools not R tools.
--
Sent from my phone. Please excuse my brevity.
On August 9, 2016 4:35:44 PM PD
Choose
A
Different
Mirror
--
Sent from my phone. Please excuse my brevity.
On August 12, 2016 3:53:03 AM PDT, "Dayalan, Nithya"
wrote:
>Hi Team,
>
>We are receiving the below message while updating the package. Please
>help.
>
>> install.packages("parallel", lib="D:/Program
>Files/R/R-3.2.5/
This may not have anything to do with the OP's problem, but if permissions are
an issue then it should be mentioned.
One problem that some windows users encounter is thinking they should "Run As"
administrator when installing or running R, rather than letting Windows UAE
prompt them for privi
ot;, "NJ", "NY", "OH", "", "", "", "",
"CA", "NY", "PA", "PA", "TN", "", "", "", "", "PA", "MD",
&quo
Use of "get" usually means you are doing something wrong in setting up your
approach to a problem. That is, if you design your interface to your functions
to be overly general, it will become full of surprises later.
If in fact the data you are interested in referring to is a column in a data
My example shows that using a dedicated environment allows you to segregate the
items loaded from the save file from the objects you are working with. It has
the advantage that any kind of object or collection of objects can be loaded
that way. It has the disadvantage that you have to keep track
Not our problem. Please correspond with the maintainer of that package.
--
Sent from my phone. Please excuse my brevity.
On August 17, 2016 3:23:33 AM PDT, Shivi Bhatia wrote:
>Hi David,
>
>If this has loaded correctly then it still does not allow me to run
>iv.multi command where a can add al
I cannot imagine why you would want ifelse to support an na.rm argument, and
your phrase 'still retains the missing data denoted as "NA"' seems exactly how
ifelse works anyway. You may need to study how NA values work... basic things
like TRUE & NA ==NA and when you should use is.na(). The"Intr
Cross-posting [1] is not acceptable on R-help, particularly if you don't let
reasonable time pass and inform us of the other posting. Topics not related to
the R language are off-topic here (this is about slurm, not R).
[1]
http://stackoverflow.com/questions/38991287/r-jobs-on-slurm-running-on
There are at least four layers of software involved here: RODBC, ODBC, HS2 and
PAM. If the question involved RODBC then R-sig-db would be a much better bet
for relevant experience (see the Posting Guide). However, your question seems
to be about getting ODBC to talk with HS2... a topic for whic
If we R users unfamiliar with the details of the CopyDetect package are to be
able to help, we would need a reproducible example that includes data. See to
http://www.catb.org/esr/faqs/smart-questions.html and
http://adv-r.had.co.nz/Reproducibility.html for discussion on how to ask for
help on
Your link did not take me to the code you reference... Google does not make
entire books available online which may have something to do with my
difficulty. This is one reason the Posting Guide asks you to post a
self-contained, reproducible example. Your use of HTML format in your posting
to
Undoubtedly. Consider nlme::plot.ACF as one possibility. Roll your own is also
feasible.
--
Sent from my phone. Please excuse my brevity.
On August 20, 2016 5:28:04 AM PDT, Naresh Gurbuxani
wrote:
>Using lattice package, is it possible to plot autocorrelation functions
>similar to acf in sta
This is not normal. I suggest making use of the maintainer() and sessionInfo()
functions.
--
Sent from my phone. Please excuse my brevity.
On August 24, 2016 7:47:25 AM PDT, Partha Sinha wrote:
>I am using windows 7 , R version 3.3.1
>whenever I am trying use
>library(dplyr)
>i am getting the
:
>[1] stats graphics grDevices utils datasets methods base
>
>
>I tried to load ggplot2 and dplyr.
>both giving me similar problems
>
>Parth
>
>On 24 August 2016 at 20:40, Jeff Newmiller
>wrote:
>
>> This is not normal. I suggest making use of the
rom my phone. Please excuse my brevity.
On August 24, 2016 10:08:09 PM PDT, Partha Sinha wrote:
>yes. I start a fresh session and start to load the library
>
>
>On 25 August 2016 at 09:34, Jeff Newmiller
>wrote:
>
>> And the only input you give to trigger this is
>&g
You need to (re-)read the "Introduction to R" document that comes with R. R Is
not Stata, and you should not expect R to look syntactically like Stata.
Note that if you, against normal R convention, wish to manipulate the integers
that a factor is implemented with, you can create such a variabl
Based on the discussion of ORing values with characters in [1] which may
generate "unusual" characters I suspect a botched conversion from EBCDIC may
have messed with some of the data. If there are signed data fields then OP may
need to read the original file and treat it as if it were binary da
Need to re-read the "Introduction to R". Data frames ARE lists of columns. So
to convert a matrix to a list of vectors use
as.data.frame( m )
--
Sent from my phone. Please excuse my brevity.
On August 28, 2016 11:14:20 PM PDT, Marius Hofert
wrote:
>Hi,
>
>I need a fast way to split a data.fra
You cannot. However, you can load the file into a dedicated environment to keep
those names separated from your global environment. e.g. [1]
The saveRDS/loadRDS functions are an alternative handle one object at a time
without dragging the object names into the picture (you have to name the
re-l
which
requires keeping your search path in mind as you work to know when to use it).
--
Sent from my phone. Please excuse my brevity.
On August 30, 2016 10:12:32 AM PDT, Martin Maechler
wrote:
>>>>>> Jeff Newmiller
>>>>>> on Tue, 30 Aug 2016 09:36:05 -
The "c" function creates vectors. Rows of data frames are data frames, not
vectors.
new_row <- data.frame( Prod_name = "Day_name", `Date 1`=1, `Date 2`=2,`Date
3`=3 )
data_may <- rbind( new_row, data_may )
Furthermore, data frames are NOT spreadsheets. "Day_num" looks suspiciously
UNlike a
ll be able to show you how to do it
correctly.
[1] http://adv-r.had.co.nz/Reproducibility.html
--
Sent from my phone. Please excuse my brevity.
On September 4, 2016 8:28:39 AM PDT, Filippos Katsios
wrote:
>Dear Jeff,
>I am sorry but I am not allowed to share the original data. You
art )
%>% summarise( SumOfValues = sum( value ) )
)
# the group_by and summarise steps work together
On Sun, 4 Sep 2016, Filippos Katsios wrote:
Dear all,
I believe that this will be a more helpful way to put the problem:
structure(list(Prod_name = c("Banana", "Ap
Your opening assertion is false.
Provide a reproducible example and someone will demonstrate.
--
Sent from my phone. Please excuse my brevity.
On September 4, 2016 9:06:59 PM PDT, Jun Shen wrote:
>Dear list,
>
>I have a vector of strings that cannot be described by one pattern. So
>let's say
n','mg.tx.cv')
>
>> sub("^.+?\\.(.+)\\.[^.]+$","\\1",z)
>[1] "WT.CUT" "tx"
>
>
>## seems to do what was requested.
>
>Jeff would have to amplify on his initial statement however: do you
>mean that separate patterns can always be
This is not the kind of thing people know off the top of their heads, and even
if they do it is an ideal application of text search tools. Download the source
and start looking. Don't neglect the licencing terms... your use of that code
implies responsibilities on your part.
--
Sent from my ph
I am not the one who proved this... I can only respond to your suggested
counterexamples.
--
Sent from my phone. Please excuse my brevity.
On September 5, 2016 9:01:12 AM PDT, Bert Gunter wrote:
>Jeff:
>
>It is not obvious to me that the ability to *match* an arbitrary
>pattern (i
It is not the implementation of regex that requires double backslashes, but the
R string parser. You can use cat to see what the pattern looks like to the
parser. Try
cat( "\\(.*?\\)" )
--
Sent from my phone. Please excuse my brevity.
On September 6, 2016 6:33:15 AM PDT, Sarah Goslee
wrote:
That step is easy, but context is hard. You really need to provide a
reproducible example. There are many models, many analysis tools, and many
timescales to choose from. In fact, this could easily be mistaken for a
question about statistics (not really on-topic here) since you have failed to
That is contributed code. It could do anything the author felt like. I
recommend reading the source code.
--
Sent from my phone. Please excuse my brevity.
On September 5, 2016 11:52:15 PM PDT, Agustin Lobo wrote:
>Any reason why the R-square prob is not calculated by randomization in
>lmPerm::
>>
>>> replace this **
>>> > pat <- do.call(paste,c(as.list(pat), sep="|"))
>>>
>>> > sub(paste0("^[^b]*(",pat,").*$"),"\\1",z)
>
way... please aim to make your examples reproducible. It would have
been easy for you to define the necessary variables in example form
rather than sending a non-reproducible example.
On Tue, 6 Sep 2016, Jun Shen wrote:
Hi Jeff,
Thanks for the reply. I tried your suggestion and it doesn'
My error. However, Jun has been severely abusing them... such use is
unusual, and the "(?:" non-capturing group marker was invented because the
capture side effect is so central to the use of the regular parenthesis.
On Tue, 6 Sep 2016, Bert Gunter wrote:
Jeff:
Not sure what yo
Many things are possible, especially if you read the Posting Guide which tells
you you that questions involving compiling R belong on R-devel, not R-help.
--
Sent from my phone. Please excuse my brevity.
On September 7, 2016 1:17:10 AM PDT, Chinmay Borwankar
wrote:
>Hi,
>I want to integrat
Should be working, so the devil is in the details you are not showing. Please
provide a reproducible (self-contained) example [1] and post in plain text
rather than HTML formatted email to avoid code corruption.
[1] http://adv-r.had.co.nz/Reproducibility.html
--
Sent from my phone. Please excu
Read the Posting Guide mentioned at the bottom of this message.
Learn how to pose a question online. [1]
Post using plain text format so your code doesn't get damaged by the HTML
formatting.
[1] http://adv-r.had.co.nz/Reproducibility.html
--
Sent from my phone. Please excuse my brevity.
On
You don't say where any of this code you are looking at came from, but I
suspect [1]. If you feel the author of that site is failing to explain their
answers sufficiently, please communicate that to them, not us.
I agree that the documentation file for with() is rather opaque to a beginner
and
Your architecture has a bad smell to me. For one thing you are mixing different
units in the same vector but should be putting multiple instances of the same
variable into one vector. Lists of vectors (data frames) are typically used
when multiple variables need to be grouped.
Another problem i
es), 1, function(a) do.call(func2, as.list(a)))
although this does work:
do.call(func2, as.list(c(10, 121)))
And, this also works:
apply(expand.grid(temps,times), 1, function(a) do.call("+", as.list(a)))
There is some subtlety here I don't understand.
Thanks,
Steve
-Or
_
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproduci
Perhaps use the correct function. (Just one little letter off...)
--
Sent from my phone. Please excuse my brevity.
On September 11, 2016 10:57:39 PM PDT, Chris Evans wrote:
>I am trying to read activity data created by Garmin. It outputs dates
>like this:
>
>"Thu, 25 Aug 2016 6:34 PM"
>
>The pr
If you think you might want to put this function into a package, it would be
much better to use gsub instead of passing the job off to an external program,
because non-POSIX operating systems (Windows) will be a headache to support.
--
Sent from my phone. Please excuse my brevity.
On September
Your example is not reproducible [1], so the apparent error in it is
distracting... perhaps you meant
kidmomhs <- kidmomhs[kidmomhs$kid_score != min(kidmomhs$kid_score),]
yes, this creates a copy, and because the object name is re-used on the left
side the original memory gets returned to the m
This is not an R concept, and it may be highly specific to the SQL Server API
rather than the ODBC API. You might try doing as the Posting Guide recommends
and posting in the R-sig-db mailing list. I would also recommend that you
figure out from Microsoft documentation what programming API your
For this query I would rather recommend [1] as reference, though Marc's
suggestion to switch mailing lists is best.
[1] https://cran.r-project.org/bin/linux/ubuntu/
--
Sent from my phone. Please excuse my brevity.
On September 13, 2016 6:44:29 AM PDT, Loris Bennett
wrote:
>Luigi Marongiu wri
excuse my brevity.
On September 13, 2016 10:57:52 PM PDT, Loris Bennett
wrote:
>Jeff Newmiller writes:
>
>> For this query I would rather recommend [1] as reference, though
>> Marc's suggestion to switch mailing lists is best.
>>
>> [1] https://cran.r-project.o
What, like the colClasses argument? Darn that ellipsis and its consequent
deferred documentation... but it _is_ mentioned in passing in ?read.fwf.
--
Sent from my phone. Please excuse my brevity.
On September 13, 2016 10:54:44 PM PDT, Erich Neuwirth
wrote:
>Since many people commenting on the
I never detach packages. I rarely load more than 6 or 7 packages directly
before restarting R. I frequently re-run my scripts in new R sessions to
confirm reproducibility.
--
Sent from my phone. Please excuse my brevity.
On September 14, 2016 1:49:55 AM PDT, Alexander Shenkin
wrote:
>Hi Henr
The incorrect results are unfortunate and can trip up the inexperienced user,
but this problem is straightforward to resolve if you explicitly specify which
versions of the conflicting functions to use. The more interesting question I
saw was whether the intent is to deprecate plyr, but so far t
not attach it, but use the plyr:: notation.
>I agree that plyr is something else as dplyr, and unfortunately plyr
>will be used for some time.
>
>Verzonden vanuit Mail voor Windows 10
>
>Van: Jeff Newmiller
__
R-help@r-project.org mail
This question is missing pieces... the example is incomplete.
--
Sent from my phone. Please excuse my brevity.
On September 15, 2016 9:35:45 PM PDT, Manohar Reddy
wrote:
>Hi ,
>
>
>
>I have data something looks like below (or PFA), but when I’m
>extracting
>month using *strftime* function th
SQLite only understands certain fundamental data types, and neither Date nor
POSIXct types are among them. They get stored as their internal numeric
representations.
The internal numeric representations of Date and POSIXct are incompatible. You
are sending Dates to SQLite and trying to then in
has no date and time types.
library(sqldf)
DF <- data.frame(d = as.Date("2000-01-01"))
sqldf("select d+1 as d from DF") # return next day
d
1 2000-01-02
At the same time iif you really need to do serious date processing on
the SQL side it's much easier wi
Appending to lists is only very slightly more efficient than incremental
rbinding. Ideally you can figure out an upper bound for number of records,
preallocate a data frame of that size, modify each element as you go in-place,
and shrink the data frame once at the end as needed. If you cannot do
You desperately need to read the Posting Guide mentioned at the bottom of every
posting on this list. Avoid attachments (your code did not come through), keep
sample data size minimal, don't reply to other topic messages (start a fresh
email thread so your message doesn't get buried in other peo
What do you think?
This is covered in the Introduction to R document that comes with R.
--
Sent from my phone. Please excuse my brevity.
On September 19, 2016 8:37:30 PM PDT, John wrote:
>Hi,
>
> I have the following dataframe:
>
>> temp<-data.frame(a=c(1,1,2), b=2:4, c=1:3)
>> row.names(temp)
I suppose you can do what works for your data, but I wouldn't recommend
na.rm=TRUE because it hides problems rather than clarifying them.
If in fact your data includes true NA values (the letters NA or simply nothing
between the commas are typical ways this information may be indicated), then
dta$Discharge )
dta[ is.na( dta$DischargeNum ), "Discharge" ]
--
Sent from my phone. Please excuse my brevity.
On September 20, 2016 3:42:39 PM PDT, lily li wrote:
>Thanks. Then what should I do to solve the problem?
>
>On Tue, Sep 20, 2016 at 4:30 PM, Jeff Newmiller
>
>wrot
ting
>numeric
>>> to factor? Thanks a lot.
>>>
>>>
>>>
>>> On Tue, Sep 20, 2016 at 4:42 PM, lily li
>wrote:
>>>
>>> > Thanks. Then what should I do to solve the problem?
>>> >
>>> > On Tue, Sep 20, 2016 at 4:3
601 - 700 of 4330 matches
Mail list logo