similar to: Translate the elements of a dataframe

Displaying 20 results from an estimated 10000 matches similar to: "Translate the elements of a dataframe"

2010 Jul 16
1
I need help making a data.fame comprised of selected columns of an original data frame.
I must have missed something simple, but still, i don't know what. I obtained my basic data as follows: x <- sprintf("SELECT m_id,sale_date,YEAR(sale_date) AS sale_year,WEEK(sale_date) AS sale_week,return_type,0.0001 + DATEDIFF(return_date,sale_date) AS elapsed_time FROM `merchants2`.`risk_input` WHERE DATEDIFF(return_date,sale_date) IS NOT NULL") moreinfo <- dbGetQuery(con,
2010 Jul 16
1
Troubles with DBI's dbWriteTable in RMySQL
I am feeling rather dumb right now. I created what I thought was a data.frame as follows: aaa <- lapply(split(moreinfo,list(moreinfo$m_id),drop = TRUE), fun_m_id) m_id_default_res <- do.call(rbind, aaa) print("==========================================") m_id_default_res print("==========================================") ndf <- m_id_default_res[, c('mid',
2013 Jun 18
1
install a package made using bioconductor package pdInfoBuilder
Dear maintainer, I used bioconductor package, pdInfoBuilder, to make a microarray platform annotation package. I named this package, pd.pdinfo.gpl11164.ndf.txt. This "self-made package" is to be used with oligo package. Prior to using oligo package, I need to install the annotation package, pd.pdinfo.gpl11164.ndf.txt, and cannot just copy it to the library tree. I tried using the
2012 Oct 22
2
Problem installing ndf library
Hello, I am a new user of R and Linux (debian squeeze), and I am trying to install the ncdf library. First I don't know wich is the best to use (ncdf or ncdf4), But not matter the one I tried to install, it always failled. I try to find a solution to this common problem on the web, but I never find the good way to solve it. I hope you could help me I try many things during two days and now I
2009 May 31
1
Error:non-numeric argument in my function
Hello! I have a function: zywnoscCalosc<- function( jedzenie, n1, n2, n3, n4, d1, d2, d3, d4 ) { ndf <- data.frame(nn1=n1,nn2=n2,nn3=n3,nn4=n4) ddf <- data.frame(dd1=d1,dd2=d2,dd3=d3,dd4=d4) for (i in 1:length(n1)){ wekt_n = ndf[i,] wekt_n_ok = wekt_n[!is.na(wekt_n)] dl_n = length(wekt_n_ok) wynik = (1*wekt_n_ok)/(1*dl_n) } } and I get an error like this: Error in 1 * wekt_n_ok :
2004 Jul 30
2
pairwise difference operator
There was a BioConductor thread today where the poster wanted to find pairwise difference between columns of a matrix. I suggested the slow solution below, hoping that someone might suggest a faster and/or more elegant solution, but no other response. I tried unsuccessfully with the apply() family. Searching the mailing list was not very fruitful either. The closest I got to was a cryptic chunk
2009 Jun 02
2
What do you think about my function?
Hello, I want to know what do you think about my function. I know that it isn't briliant :/ but what do you think? What I should do that my function will be better? (now is very slow and not ideal, sometimes I also get a mistake!) ########## My function ############################################# dzieci<-transform(dzieci, zywnosc=0) zywnoscCalosc<- function( jedzenie, sklep, n1, n2,
2009 Jun 08
6
Strange indices of support verctors from e1071
Hello, In the attached file training.csv (I apologize for the large file) I have 238 objects belonging to 13 classes, which are described by 183 properties. I would like to find a svm model for these objects. I tried the following R statements. library('e1071') datatraining <- read.csv("training.csv",head=TRUE) names<-names(datatraining) print("before
2009 Feb 26
1
using predict method with an offset
Hi, I have run into another problem using offsets, this time with the predict function, where there seems to be a contradiction again between the behavior and the help page. On the man page for predict.lm, it says Offsets specified by offset in the fit by lm will not be included in predictions, whereas those specified by an offset term in the formula will be. While it indicates nothings about
2009 May 08
3
'Dynamic' 3D plot
Hi, I am looking for a R package to draw 3d plot. But not in a static way like scatterplot3d or stuff like that. I would like to make rotate the plot, to zoom/unzoom etc..., actually to render the graph 'dynamic'... (for the biologist and bioinformatician, a R package which permitts to reproduce what pdb viewer does). Does a Way exist to do something like that in R ? Thanks,
2008 Dec 03
1
function qt can fails if ndf < 1 (PR#13364)
Full_Name: Gerard Torrent Version: R version 2.8.0 (2008-10-20) OS: Linux 2.6.27.5-41.fc9.x86_64 #1 SMP Submission from: (NULL) (85.52.227.233) In some cases qt complains about NaNs and don't gives the correct result: > qt(0.1,, 0.1) [1] NaN Warning message: In qt(p, df, lower.tail, log.p) : NaNs produced But the result can be found: > pt(-1.60443e+06, 0.1) [1] 0.09999997 If I
2005 Jul 01
1
scope argument in step function
Thanks a lot for help in advance. I am switching from matlab to R and I guess I need some time to get rolling. I was wondering why this code : > fit.0 <- lm( Response ~ 1, data = ds3) > step(fit.0,scope=list(upper=~.,lower=~1),data=ds3) Start: AIC= -32.66 Response ~ 1 Call: lm(formula = Response ~ 1, data = ds3) Coefficients: (Intercept) 1.301 is not working
2002 Apr 01
2
creating an output file name using cat
I am having problems trying to create file names using the cat function. I have an array of column headers, called cnames[] that I want to use as part of a jpeg output file. Here is the basic code I am using: data<-read.csv("inputfile.txt") cnames<-colnames(data) for(i in 9:dim(data)[2]) { ...
2009 Mar 12
1
read.xls and name of worksheet
Hi, I would like to some excel files with some worksheets. I tried this with the following R script: library(gdata) i<-1 rc<-0 while(rc != "try-error") { wksh<-try(read.xls("cluster-microarray-FW.xls",sheet=i,verbose=TRUE,perl="perl")) rc<-class(wksh) print(sprintf("------- i=%2d rc=%s ---------------",i,rc)) if (rc !=
2010 Feb 09
3
subset in a matrix
Hi, I have a matrix of data values like the example bellow. I would like to extract a subset of the matrix for the values where the first column is negative. I am using the subset function. However, I am getting an error message that the conditional variable doe snot exist. For some reason, the subset operation only works if I transform the matrix to a data set using as.data.set(). The help
2018 Jul 22
4
Samba and CNAME
Hello, we successfully migrated from a Samba 3.x NT Domain to a Samba AD Domain using Samba 4.7.x. However, there are still some issues and I hope for your help. The biggest problem so far follows: For historical reasons our Samba file servers carry a lot of aliases. Now that they have become AD Members I did set a lot of CNAMEs in the AD DNS (using the Windows DNS Tool). Most of the aliases
2012 Sep 06
2
How can I improve an ugly, dumb hack
Hi Folks: Here's the situation: > m <- cbind(x=letters[1:3], y = letters[4:6]) > m x y [1,] "a" "d" [2,] "b" "e" [3,] "c" "f" ## m is a 2 column character matrix > d <- data.frame(a=1:3,b=4:6) > d$c <- m > d a b c.x c.y 1 1 4 a d 2 2 5 b e 3 3 6 c f ## But please note (as was remarked
2008 Nov 16
1
help.start() displays index.html in emacs (PR#13293)
Full_Name: Juergen Rose Version: 2.8.0 (2008-10-20) OS: Linux 2.6.27.4 x86_64 Intel Submission from: (NULL) (87.185.220.122) If I start as ordinary user rose R and help.start(), the help is displayed in emacs. If I do as the user root, file:///tmp/Rtmpyzlc7Y/.R/doc/html/index.html is shown as expected in a firefox windows. So it seems to be connected with my private configuration. But I can not
2023 Jan 31
2
Upgrading from Samba 4.8.2 to 4.15.5
31.01.2023 08:55, Matt Savin via samba ?????: > In group policies use DNS aliases, then you'll need to change only DNS > entries for these aliases to point to a new host(s). I'd say don't use simple dns aliases (cnames) in a DC, but use SPNs instead (see samba-tool spn). This will manage CNAMEs too, and also manages the KRB tickets and proper autentication of the server to the
2008 May 16
2
OT DNS Question
Hi Everyone, I am currently reviewing the DNS records for the organization I work for and have one area I would like other peoples thoughts on. Would there ever be a situation where you need to have multiple A records pointing to the same IP Address? Currently we have a small number of cases where one IP Address has multiple A Records. This seems like a bad idea to me and I would replace