similar to: Create design matrix

Displaying 20 results from an estimated 40000 matches similar to: "Create design matrix"

2017 Nov 10
3
update R version in windows
However, trying this on Linux Mint gave package ?installr? is not available (for R version 3.4.2) Has the package not been updated yet? JN Try the installr package. It was designed for this purpose. On Fri, Nov 10, 2017 at 11:49 AM, Bond, Stephen <Stephen.Bond at cibc.com> wrote: > Is there a utility which will allow me to upgrade my R version and update all packages from the old
2018 Mar 22
2
how to add a child to a child in XML
Big thanks. newXMLNode works great. Wonder why it is not included in the documentation. There is newXMLDoc and newXMLNamespace, but no mention of newXMLNode. Stephen From: Ben Tupper [mailto:btupper at bigelow.org] Sent: Wednesday, March 21, 2018 6:18 PM To: Bond, Stephen Cc: r-help Subject: Re: [R] how to add a child to a child in XML Hi, XML doesn't use the `$` to access child nodes.
2013 Sep 09
1
windowing
Is there a package or a command that does window aggregation like select sum(col1) over (partition by col2, col3 order by col4 rows between unbounded preceding and current row) as sum1 from table1 ; the above is Netezza syntax, but Postgre has same capability. Stephen B [[alternative HTML version deleted]]
2018 Mar 22
0
how to add a child to a child in XML
Hi, It's a reasonable question. The answer is that it actually is included, but there are many instances across packages where multiple functions are documented on a single help page. The following brings up such a page... (for XML_3.98-1.9) > library(XML) > ?newXMLNode You can see the same on line... https://www.rdocumentation.org/packages/XML/versions/3.98-1.9/topics/newXMLDoc
2018 Mar 22
1
how to add a child to a child in XML
Just to clarify and hopefully catch the attention of the maintainer: The newXMLNode function is not mentioned in: https://cran.r-project.org/web/packages/XML/XML.pdf which supposedly describes all functions in the package. Stephen From: Ben Tupper [mailto:btupper at bigelow.org] Sent: Thursday, March 22, 2018 10:40 AM To: Bond, Stephen Cc: r-help Subject: Re: [R] how to add a child to a
2017 Nov 10
0
update R version in windows
This issue does not exist on Linux. My Ubuntu updates both R and all packages. Stephen B -----Original Message----- From: J C Nash [mailto:profjcnash at gmail.com] Sent: Friday, November 10, 2017 1:19 PM To: r-help; RICHARD M. HEIBERGER; Bond, Stephen Subject: Re: [R] update R version in windows However, trying this on Linux Mint gave package ?installr? is not available (for R version
2018 Mar 21
2
how to add a child to a child in XML
I am trying to add a child to a child using XML package in R. the following fails library(XML) node1 <- c("val1","val2","val3") names(node1) <- c("att1","att2","att3") root <- xmlNode("root", attrs=node1) node2 <- LETTERS[1:3] names(node2) <- paste("name",1:3,sep="") root <-
2017 Nov 10
3
update R version in windows
Is there a utility which will allow me to upgrade my R version and update all packages from the old version? If I manually upgrade, then I have to manually re-install 50 packages. Thank you. Stephen B [[alternative HTML version deleted]]
2009 Oct 09
2
weigths in nls (PR#13991)
Potential bug: I mistyped weights in the call ('weigths') and it did not produce any error= message. The coefs were exactly the same like without weights, so I was su= spicious and when weights(nls1) gave NULL, I saw my typo. Usually the function will say "Unused arguments", which shows you the error= , but not nls. Regards Stephen [[alternative HTML version deleted]]
2009 Jan 10
2
Print specific matrix value???
Hello All, I'm trying to print specific row and column for Observed_Scores matrix, however, when I execute the command "Observed_Scores[1,1]", I get the message "Error in Observed_Scores[1, 1] : incorrect number of dimensions". Could you please help and let me know where is the mistake? Here is my program: library(ltm) library(psych) # Settting the working directory
2018 Mar 21
0
how to add a child to a child in XML
Hi, XML doesn't use the `$` to access child nodes. Instead use either `[name]` to get a list of children of that name or `[[name]]` to get the just the first child of that name encountered in the genealogy. Thus for your example... > root$child1 NULL > root[['child1']] <child1 name1="A" name2="B" name3="C"/> On the other hand, you might
2014 Oct 07
3
lattice add a fit
What is the way to add an arbitrary fit from a model to a lattice conditioning plot ? For example xyplot(v1 ~v2 | v3,data=mydata, panel=function(...){ panel.xyplot(...) panel.loess(...,col.line="red") } ) Will add a loess smoother. Instead, I want to put a fit from lm (but not a simple straight line) and the fit has to be done for each panel
2012 Mar 30
3
ff usage for glm
Greetings useRs, Can anyone provide an example how to use ff to feed a very large data frame to glm? The data.frame cannot be loaded in R using conventional read.csv as it is too big. glm(...,data=ff.file) ?? Thank you Stephen B
2008 Dec 26
3
Simulating dataset using Parallel Latent CTT model?
I am trying to simulate a dataset using Parallel Latent CTT model and this is what i have done so far: (START) #Importing psych library for all the simulation related functions library(psych) # Settting the working directory path to C:/NCME path="C:/NCME" setwd(path) #Using the function to generate the data GenData <- congeneric.sim(N=500, loads =
2017 Dec 20
2
offset with a factor
Knowledgeable useRs, Please, advise how to use offset with a factor. I estimate monthly effects from a much bigger data set as monthly effects seem to be stable, and other variables are estimated from a small, but recent data set as there is variation in those non-seasonal coefficients. How can I use the seasonality estimates from the big data set as an offset provided to the small data set. I
2009 Jan 28
1
stack data sets
Hi All, I'm generating 10 different data sets with 1 and 0 in a matrix form and writing the output in separate files. Now I need to stack all these data sets in one vector and I know that stack only operates on list or data frame however I got these data sets by converting list to a matrix so can't go backwards now. Is there a way i can still use Stack? Please see the program:
2010 Oct 12
5
aggregate with cumsum
Hello everybody, Data is myd <- data.frame(id1=rep(c("a","b","c"),each=3),id2=rep(1:3,3),val=rnorm(9)) I want to get a cumulative sum over each of id1. trying aggregate does not work myd$pcum <- aggregate(myd[,c("val")],list(orig=myd$id1),cumsum) Please suggest a solution. In real the dataframe is huge so looping with for and subsetting is not a
2017 Jun 13
1
fedback from foreach
Hi useRs, I am running a foreach loop and hoped to get a small message when it hits a multiple of 1000, but it does not work. p <- foreach(i=1:10000, .combine='c') %dopar% { if(i%%1000==0) print(i) sqrt(i) } What is the proper way to do it. Thanks everybody. Stephen B [[alternative HTML version deleted]]
2012 Dec 17
1
rms R code
Greetings, useRs. Does anybody have replication of the examples from the RMS book by Harrell coded in R? I find that most the code does not work and it takes too much time to debug. For example from p.276 > age.t <- w[,"age"] > f.full <- lrm(cvd~scored(rx)+rcs(dtime,5)+age.t+wt.t+pf.t+hx+sbp+ekg.t+sz.t+sg.t+ap.t+bm+hg.t,x=T,y=T) Error in model.frame.default(formula = cvd ~
2010 Aug 26
1
sqldf syntax
Please correct the following > sqldf("update esc left join forwagg on esc.ym=forwagg.Date set esc.ri2=forwagg.N1 where esc.age=12","select * from main.esc") Error in sqliteExecStatement(con, statement, bind.data) : RS-DBI driver: (error in statement: near "left": syntax error) Thanks. Stephen [[alternative HTML version deleted]]