search for: ruipbarrada

Displaying 20 results from an estimated 356 matches for "ruipbarrada".

Did you mean: ruipbarradas
2018 Aug 05
2
Is this a bug in `[`?
...] > #> [1] 4 > c(1, 2, 3, 4)[-seq_len(2)] > #> [1] 3 4 > c(1, 2, 3, 4)[-seq_len(1)] > #> [1] 2 3 4 > c(1, 2, 3, 4)[-seq_len(0)] > #> numeric(0) > Created on 2018-08-05 by the reprex package (v0.2.0.9000). > > On Sun, Aug 5, 2018 at 3:58 AM Rui Barradas <ruipbarradas at sapo.pt > <mailto:ruipbarradas at sapo.pt>> wrote: > > > > ?s 15:51 de 04/08/2018, I?aki ?car escreveu: > > El s?b., 4 ago. 2018 a las 15:32, Rui Barradas > > (<ruipbarradas at sapo.pt <mailto:ruipbarradas at sapo.pt>>) escribi?:...
2012 Jul 07
11
Splitting a character vector.
I am lousy at simple regex and I have not found a solution to a simple problem. I have a vector with some character values that I want to split. Sample data dd1 <- c( "XXY (mat harry)","XXY (jim bob)", "CAMP (joe blow)", "ALP (max jack)") Desired result dd2 <- data.frame( xx = c("XXY", "XXY", "CAMP",
2018 Aug 04
3
Is this a bug in `[`?
?s 15:51 de 04/08/2018, I?aki ?car escreveu: > El s?b., 4 ago. 2018 a las 15:32, Rui Barradas > (<ruipbarradas at sapo.pt>) escribi?: >> >> Hello, >> >> Maybe I am not understanding how negative indexing works but >> >> 1) This is right. >> >> (1:10)[-1] >> #[1] 2 3 4 5 6 7 8 9 10 >> >> 2) Are these right? They are at least surpri...
2018 Feb 05
0
find unique and summerize
Thank you so much Rui! On Sun, Feb 4, 2018 at 12:20 AM, Rui Barradas <ruipbarradas at sapo.pt> wrote: > Hello, > > Please always cc the list. > > As for the question, I believe the following does it. > > a <- strsplit(mydata$ID, "[[:alpha:]]+") > b <- strsplit(mydata$ID, "[[:digit:]]+") > > a <- sapply(a, `[`, 1) &gt...
2012 Nov 14
5
aggregate combination data
Dear R users, I want to aggregate all *d *data from all combination of n *plots* taken by k. Thank very much! My data is like that: plot d 1 14 1 13 1 12 1 14 1 18 1 20 1 21 1 43 1 108 1 43 2 41 2 61 2 83 2 61 2 84 2 45 2 21 2 12 2 11 ... 100 10 100 12 -- --- Catalin-Constantin ROIBU Forestry engineer, PhD Forestry Faculty of Suceava
2017 Sep 21
2
rcorr error in R stat
...hical parameter > 43: In cbind(x, y) : > ? number of rows of result is not a multiple of vector length (arg 2) > ? > Would it help if I send the two csv files to you? I'd really > appreciate your help. > > Thanking you > ? > > ------------------------- > FROM: ruipbarradas at sapo.pt <ruipbarradas at sapo.pt> > SENT: Wednesday, September 20, 2017 5:21:04 PM > TO: Chaitanya Ganne > SUBJECT: Re: rcorr error in R stat > > Hello, > > Maybe I'm completely off, but read.csv returns data.frames, which > are lists with a dim attribute. &g...
2017 Sep 21
0
rcorr error in R stat
Hello, Also, the other file, NPA.csv, is not in tabular form. Can you please reformat it? Rui Barradas Citando ruipbarradas at sapo.pt: > Hello, > > Please keep this on the list, always cc r-help. > One of the files in your attachment is empty: > > y <- read.csv(file.choose("GT.csv")) > Error in read.table(file = file, header = header, sep = sep, quote = > quote,? : > ? no line...
2018 Aug 05
0
Is this a bug in `[`?
...3, 4)[-seq_len(2)] >> #> [1] 3 4 >> c(1, 2, 3, 4)[-seq_len(1)] >> #> [1] 2 3 4 >> c(1, 2, 3, 4)[-seq_len(0)] >> #> numeric(0) >> Created on 2018-08-05 by the reprex package (v0.2.0.9000). >> >> On Sun, Aug 5, 2018 at 3:58 AM Rui Barradas <ruipbarradas at sapo.pt >> <mailto:ruipbarradas at sapo.pt>> wrote: >> >> >> >> ??? ?s 15:51 de 04/08/2018, I?aki ?car escreveu: >> ???? > El s?b., 4 ago. 2018 a las 15:32, Rui Barradas >> ???? > (<ruipbarradas at sapo.pt <mailto:ruipbarradas at s...
2012 Jul 14
3
Can't understand syntax
..."]] [!(is.na(test[["v2"]]))] <- test [["v2"]] [!(is.na (test[["v2"]]))] test [["result"]] [!(is.na(test[["v3"]]))] <- test [["v3"]] [!(is.na (test[["v3"]]))] thanks! On Fri, Jul 13, 2012 at 6:41 AM, Rui Barradas <ruipbarradas@sapo.pt> wrote: > Hello, > > Check the structure of what you have, df and newdf. You will see that in > df dateTime is of class POSIXlt and in newDf newDateTime is of class > POSIXct. > > Solution: > > [...] > df$dateTime <- strptime(df$dateTime,"%m/%d/%Y...
2016 Apr 15
0
aggregate combination data
...> want for each combination to insert a column with combination ID (C1 > for first iteration to Cn for last one)? Is there a possibility to > do that? > ? > Thank you very much! > ? > best regards! > ? > Catalin > ? On 15 November 2012 at 13:29, Rui Barradas <ruipbarradas at sapo.pt> wrote: >> Hello, >> >> Sorry but now I don't understand, what you are saying is that you >> want all the results in just one df? >> >> all <- do.call(rbind, result) >> >> But this creates just one very large df. >> >&...
2012 Sep 18
0
Appending many different and separate Excel files using R
...t;> writeWorksheetToFile(output.file, data = result, sheet = "AllSteps", > + startRow = 1, startCol = 1) > Error: IllegalArgumentException (Java): File extension "csv" not supported! Only *.xls and *.xlsx are allowed! > > > --- On Wed, 22/8/12, Rui Barradas <ruipbarradas at sapo.pt> wrote: > > > From: Rui Barradas <ruipbarradas at sapo.pt> > Subject: Re: [R] Appending many different and separate Excel files using R > To: "Amir Kasaeian" <amir_kasaeian at yahoo.com> > Cc: "r-help" <r-help at r-project.org>...
2018 Aug 05
2
Is this a bug in `[`?
...programming languages work in general). Instead, the sequence is evaluated in the first place, and then the sign may apply as long as you provided something that can hold a sign. And an empty element has no sign, so the sign is lost. I?aki > > On Sun, Aug 5, 2018 at 3:58 AM Rui Barradas <ruipbarradas at sapo.pt> wrote: >> >> >> >> ?s 15:51 de 04/08/2018, I?aki ?car escreveu: >> > El s?b., 4 ago. 2018 a las 15:32, Rui Barradas >> > (<ruipbarradas at sapo.pt>) escribi?: >> >> >> >> Hello, >> >> >> >&g...
2018 May 02
0
Merging dataframes
...ail.com>> wrote: ---------- Forwarded message ---------- From: peter dalgaard <pdalgd at gmail.com<mailto:pdalgd at gmail.com>> Date: Tue, May 1, 2018 ar-help at r-project.org<mailto:r-help at r-project.org>t 9:05 PM Subject: Re: [R] Merging dataframes To: Rui Barradas <ruipbarradas at sapo.pt<mailto:ruipbarradas at sapo.pt>> Cc: Chintanu <chintanu at gmail.com<mailto:chintanu at gmail.com>>, R help <r-help at r-project.org<mailto:r-help at r-project.org>> I'd expect more like setdiff(A$key, B$key) and vice versa. Or, if you want the a...
2012 Jul 16
4
Error in as.xts
Hi I got the following error using as.xts Error in xts(x, order.by = order.by, frequency = frequency, ...) : NROW(x) must match length(order.by) Here is how the data looks like > d1 <- read.csv(file.path(dataDir,"AppendixA-FishCountsTable-2009.csv"), as.is=T) > d1[1:3,] dive_id date time species count size site depth level TRANSECT VIS_M 1 62 10/12/2009
2018 Oct 07
4
Warning when calling formals() for `[`.
Hello, I don't see why you say that the documentation seems to be wrong: class(args(`+`)) #[1] "function" args() on a primitive does return a closure. At least in this case it does. Rui Barradas ?s 14:05 de 07/10/2018, Peter Dalgaard escreveu: > There is more "fun" afoot here, but I don't recall what the point may be: > >> args(get("+"))
2024 Feb 23
1
help - Package: stats - function ar.ols
...notepad file and send that? You could also paste it into your email IF your email is configured to send text and NOT html. TIm -----Original Message----- From: R-help <r-help-bounces at r-project.org> On Behalf Of Pedro Gavronski. Sent: Friday, February 23, 2024 5:00 AM To: Rui Barradas <ruipbarradas at sapo.pt> Cc: r-help at r-project.org; r-help-request at r-project.org Subject: Re: [R] help - Package: stats - function ar.ols [External Email] Hello, Thanks for the reply Rui and for pointing out that I forgot to attach my code. Please find attached in this email my code and data. Thank...
2013 Jul 22
4
How to split two levels several times?
Hi, I have a small problem with the function split() and would appreciate your help. I have a table called ?XXX? with 2 columns and 49 rows. The 49 rows belong to 8 different levels (electrode1, ...,electrode8). I want to split the table always at the row where ?electrode1? starts again so that I can export 7 individual dataframes (numbered ?dataframe1? to ?dataframe7?) which contain always
2018 May 21
1
removing part of a string
I would use sub("\\(.*\\)", "()", s) It is essentially the same as Rui's suggestion, but I find the purpose to be more clear. It might also be a little more efficient. HTH Ulrik On Mon, 21 May 2018, 15:38 Rui Barradas, <ruipbarradas at sapo.pt> wrote: > Hello, > > Try this. > > > ss1 <- "z:f(5, a=3, b=4, c='1:4', d=2)" > ss2 <- "f(5, a=3, b=4, c=\"1:4\", d=2)*z" > > fun <- function(s) sub("(\\().*(\\))", "\\1\\2", s) > > fu...
2018 Oct 06
1
Warning when calling formals() for `[`.
...nippet taken from `formals` doc page (the code comment is also from that doc) ? ## formals returns NULL for primitive functions. Use it in combination with ## args for this case. is.primitive(`+`) formals(`+`) formals(args(`+`)) Le sam. 6 oct. 2018 ? 13:42, Rui Barradas <ruipbarradas at sapo.pt> a ?crit : > Hello, > > I believe that this is maybe not a *feature* but at least expected > behaviour. > > The call formals(args(`[`)) breaks down to > > > > args(`[`) > NULL > > formals(NULL) > NULL > Warning message: > In formals(...
2017 Jun 01
0
Data import R: some explanatory variables not showing up correctly in summary
...-------------------------------- David L Carlson Department of Anthropology Texas A&M University College Station, TX 77840-4352 -----Original Message----- From: R-help [mailto:r-help-bounces at r-project.org] On Behalf Of Ulrik Stervbo Sent: Thursday, June 1, 2017 10:50 AM To: Rui Barradas <ruipbarradas at sapo.pt>; Tara Adcock <taraadcock1 at hotmail.com>; r-help at r-project.org Subject: Re: [R] Data import R: some explanatory variables not showing up correctly in summary Hi Tara, It seems that you categorise and count for each category. Could it be that the method you use puts every...