similar to: reshape error in 1.4 (PR#1231)

Displaying 20 results from an estimated 2000 matches similar to: "reshape error in 1.4 (PR#1231)"

2008 Apr 30
2
Summary statistics across factor levels
R users, I intention is to calculate some summary statistics across factor levels. I know that in Hmisc package there is a summary function which produces neat summary statistics when using "cross" option. I would like to produce similar output with N and Missing columns but produce a data.frame. Is there any built-in function for that? #example data install.packages("Hmisc")
2008 Nov 18
1
reshape question
Hi, It's probably a simple issue but I'm struggling with that. I'll use the example shown in the help page. head(Indometh) wide <- reshape(Indometh, v.names="conc", idvar="Subject", timevar="time", direction="wide") head(wide) reshape(wide, idvar="Subject", varying=list(2:12), v.names="conc",
2008 Nov 14
1
Superimposing y-variables in Lattice formulas
Given a data frame of a categorical variable and two continuous variables, I would like to display one continuous variable against the other for each value of the categorical variable, all superimposed on the same plot. For example: data(Indometh); str(Indometh) Classes 'nfnGroupedData', 'nfGroupedData', 'groupedData' and 'data.frame': 66 obs. of 3
2007 May 11
3
A simple question regarding plot of nls objects
Hi, I was trying to run the example of Indomethacin kinetics from the book: ## From Pinheiro/Bates, Mixed-Effects-Models in S and S-Plus, ## Springer, Second Printing 2001, Section 6.2 library(nlme) plot(Indometh) fm1Indom.nls <- nls(conc~SSbiexp(time,A1,lrc1,A2,lrc2), data=Indometh) summary(fm1Indom.nls) plot(fm1Indom.nls,Subject~resid(.),abline=0) ## .... the last plot command gives me the
2009 Dec 12
4
simple ts.plot question
*Respected Sir, I have a simple question regarding plots of time series in R. I have to plot "conc" against "time" **for each individual and display in the same panel for the in-built dataset "Indometh" in R. * ***I have six time series, say subject1.ts, subject2.ts, ............., subject6.ts. The observations are taken at an interval of 0.25 hr. All of the series
2001 May 23
2
help: exponential fit?
Hi there, I'm quite new to R (and statistics), and I like it (both)! But I'm a bit lost in all these packages, so could someone please give me a hint whether there exists a package for fitting exponential curves (of the type t --> \sum_i a_i \exp( - b_i t)) on a noisy signal? In fact monoexponential decay + polynomial growth is what I'd like to try. Thanks in advance,
2005 Sep 23
2
Strange behaviour of as.Date function
Dear All, I'm happily extracting data of temperature from an oracle db under R via RODBC. After manipulating the extracted data I put them into a data.frame 'dati' which is as follows: > dati DATA tm. UDINE/RIVOLTO tm.TORINO/CASELLE 1 2005-07-01 22.35 23.80 2 2005-07-02 22.70 22.85 3 2005-07-03 23.80
2006 Jul 24
3
random section of samples based on group membership
Hi all, I have a matrix of 474 rows (samples) with 565 columns (variables). each of the 474 samples belong to one of 120 groups, with the groupings as a column in the above matrix. For example, the group column would be: 1 1 1 2 2 2 . . . 120 120 I want to randomly select one from each group. Not all the groups have the same number of samples, some have 4, some 3 etc. Is there a function to
2006 Feb 22
1
unused factor levels in reshape
When reshaping a dataframe in which there are unused factor levels in the id variable, I get the following error: Error in if (!all(really.constant)) warning(gettextf("some constant variables (%s) are really varying", : missing value where TRUE/FALSE needed For example, > df <- data.frame(i = factor(rep(1:5, each = 2)), t = factor(rep(1:2, 5)), x = rep(rbinom(5, 1,
2013 Mar 18
2
melt with complications
## Can someone suggest a simpler expression than either of these, with the goal ## of taking a long matrix into a wide one with exactly one of the factors converted to ## columns and all the rest retained as factors. I want something that generalizes beyond ## the three factors illustrated here. ## Rich meltTest <- data.frame(A=rep(c("B","C"), each=12),
2007 Aug 23
0
Lost in substitute: nlsList and nlme with dynamic formula
DeaR I am trying to use a dynamically create formula with nlsList and nlme, but I cannot get the environment of the string-generated formal to work similarly to the manually entered one. Any idea? Dieter #----- library(nlme) # Pinheiro/Bates p 280 fm1Indom.lis = nlsList(conc~SSbiexp(time,A1,lrc1,A2,lrc2), data=Indometh) nlme(fm1Indom.lis,random=pdDiag(A1+lrc1+A2~1)) # works... # Simulating
2006 Apr 06
1
reshape question
Hi, I have a data fram like this: date column1 column2 column3 value1 value2 value3 1-1 A B C 10 5 2 2-1 A B D 5 2 0 3-1 A B E 17 10 7 How can I reshape it to: date column1 column2 column3 v x 1-1 A B C value1 10 1-1 A B C value2 5 1-1 A B C value3 2 2-1 A B D value1 5 2-1 A B D value2 2 2-1 A B D value3 0 3-1 A B E value1 17 3-1 A B E value2 10 3-1 A B E value3 7 Thx! Regards, Richard
2009 Oct 20
0
[LLVMdev] 2.6 pre-release2 ready for testing
Hi Tanya, > 1) Compile llvm from source and untar the llvm-test in the projects > directory (name it llvm-test or test-suite). Choose to use a > pre-compiled llvm-gcc or re-compile it yourself. I compiled llvm and llvm-gcc with separate objects directories. Platform is x86_64-linux-gnu. > 2) Run make check, report any failures (FAIL or unexpected pass). Note > that you need to
2008 Oct 28
1
How to export text into separate text files
Hello, I'm producing text from my data.frame using cat function. I would like to use for loop to export each column in my data.frame into separate text files. Here is the example code r <- t(Indometh) for (i in 1:ncol(r)) { cat("Some text,", "\n") cat("\n") cat("More text, More text, More text") cat("\n")
2009 Nov 13
2
linear model and by()
Hello R list, This is a question for anyone who has used the by() command. I would like to perform a regression on a data frame by several factors. Using by() I think that I have able to perform this using the following: > lm.r <- by(master, list(Sectionf=Sectionf, startd=startd), function(x) lm (tot.c ~ starttime, data = x)) So that is, I would like to perform separate regressions for
2009 Oct 17
12
[LLVMdev] 2.6 pre-release2 ready for testing
LLVMers, 2.6 pre-release2 is ready to be tested by the community. http://llvm.org/prereleases/2.6/ If you have time, I'd appreciate anyone who can help test the release. To test llvm-gcc: 1) Compile llvm from source and untar the llvm-test in the projects directory (name it llvm-test or test-suite). Choose to use a pre- compiled llvm-gcc or re-compile it yourself. 2) Run make check,
2005 Jun 24
9
R demos
Hi All, I am currently preparing some form of slideshow introducing R and its capabilities for some colleagues. The thing will be about 30 mins, and I'd like to have some "pretty pictures" and some "amazing facts" (I'm trying to sell, obviously :)). Can I ask if it's possible to easily retrieve a gross figure of the number of functions in R considering the
2009 Oct 20
1
[LLVMdev] 2.6 pre-release2 ready for testing
G'Day Tanya, Is it too late to bring in the following patches to fix some major brokenness in the AuroraUX tool chain for 2.6? http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Driver/Tools.cpp?r1=84468&r2=84469&view=diff&pathrev=84469 http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Driver/Tools.cpp?r1=84265&r2=84266&view=diff&pathrev=84266
2005 Oct 11
2
Problems with plot function
Hello all R users, My simulation function works correctly, but I have problems with plot function. You will find the following code using it. Thank you for your help ##################################################" simulation <- function(k, n){ conc <- seq(0,10,by=0.5) #choixg <- seq(1, length(conc)) choixg <- rep(0,length(conc)) for (i in 1:length(conc)){ choixg[i]
2010 Apr 26
1
finite difference scheme for 2D differential equations
Hello everyone, I am trying to solve 2D differential equations using finite difference scheme in R. I have been able to work with the equations with only one spatial dimensions but I want to extend it to the two dimensional problem. For example i can simulate one dimensional diffusion using a code like the following. But I want to write a similar code for,say, a two dimensional diffusion