Displaying 20 results from an estimated 300 matches similar to: "predict nlme"
2015 Apr 30
2
predict nlme
Estimado Oliver Nuñez
Envío un ejemplo reproducible.
Javier Marcuzzi
# de donde tomo datos, y tiene el modelo (en el pdf)
library(MCMCglmm)
# librería con las funciónes que voy a usar
library(nlme)
datos0<-ChickWeight
# creo algunos datos que agrego a los origonales
Factor<-as.numeric(datos0$Chick)
Factor[Factor > 0 & Factor <= 10] <- 'A'
Factor[Factor > 10
2011 Mar 01
1
Distintos soft
Les consulto por lo siguiente:
Se me ocurrió usar datos de MCMCglmm en otros procedimientos de R, comparar
los resultados y el tiempo como facilidad de uso, para lo cual use LME4, los
resultados fueron parecidos, entendiendo que internamente los algoritmos
tienen diferencias, es lógico que los resultados no coincidan exactamente,
pero aproximadamente tienen que ser compatibles, en este caso
2015 Apr 28
2
Resumen diseño sencillo
Estimado Carlos Ortega
Muchas gracias, al ver su correo recordé por donde estaba eso muy fácil, copio y pego la solución, era tan fácil que no lo recordaba.
> table(d)
, , Etablecimiento = Est1
Factor
Dieta A B
1 220 0
2 0 120
3 0 0
4 0 0
, , Etablecimiento = Est2
Factor
Dieta A B
1 0 0
2 0 0
3 0 120
4 0 118
2015 Apr 28
2
Resumen diseño sencillo
Estimados
Estoy realizando algo tan sencillo que no se que forma sería la más apropiada, la situación es la siguiente, hay un data.frame con unos 500 registros, con algunas variables de las cuáles me interesa marcar solo tres, o dicho de otra forma, me interesan tres columnas, de las cuáles cada una tiene entre dos y cuatro factores. Nada complicado, me interesa colocar la combinación de los
2018 Jun 28
2
suma del resultado de multiplicar fila x columna
Buenas tardes, tengo 2 dfs: Dieta de (108x11) y Abund de (591x108).
Necesito multiplicar cada columna de la 1ª (108 elementos) por cada
fila de la 2ª (108 elementos) y crear una nueva df con las sumas de
esas multiplicaciones. He hecho esto, pero no sale y creo que está
lejos de estar bien:
Res <- matrix(nrow=nrow(Abund),ncol=ncol(Dieta))
Res <- as.data.frame(Res)
for(i in
2012 Apr 12
1
Using dcast with multiple functions to aggregate
Dear R communitiy,
I am trying to use multiple functions for aggregation within a function
call for dcast. However this seems to result in an error. Also I have not
managed to make dcast() work with fun.aggregate=sd. Please find attached
some example code using the ChickWeight data.
Many thanks for your help!
Jokel
#Chick weight example
names(ChickWeight) <- tolower(names(ChickWeight))
2010 Aug 12
2
Linear regression on several groups
I have a simple dataset of a numerical dependent Y, a numerical independent X
and a categorial variable Z with three levels. I want to do linear
regression Y~X for each level of Z. How can I do this in a single command
that is without using lm() applied three isolated times?
--
View this message in context: http://r.789695.n4.nabble.com/Linear-regression-on-several-groups-tp2322835p2322835.html
2010 Oct 01
2
Format of Output of Residuals
An excerpt from dataset ChickWeight:
??? weight Time Chick Diet
1?????? 42??? 0???? 1??? 1
2?????? 51??? 2???? 1??? 1
3?????? 59??? 4???? 1??? 1
I am interested in the residuals of the dataset.? Specifically in
saving them to another format. I have been creating text files with
sink.
CW.lm <- lm(weight ~ Diet, ChickWeight)
resid.CW.lm <- resid(CW.lm)
But when I call:
resid.CW.lm
The data
2009 Nov 14
4
Weighted descriptives by levels of another variables
I've noticed that R has a number of very useful functions for
obtaining descriptive statistics on groups of variables, including
summary {stats}, describe {Hmisc}, and describe {psych}, but none that
I have found is able to provided weighted descriptives of subsets of a
data set (ex. descriptives for both males and females for age, where
accurate results require use of sampling
2012 Sep 18
2
Formula in a data-frame
Hello all,
I'm new in R, and I have a data-frame like this (dput information below):
Specie Fooditem Occurrence Volume
1 Schizodon vegetal 1 0.05
2 Schizodon sediment 1 0.60
3 Schizodon vegetal 1 0.15
4 Schizodon alga 1 0.05
5 Schizodon sediment 1 0.90
6 Schizodon
2009 Jul 06
2
ReShape chicks example - line plots
Hi,
In the examples from the ReShape package there is a simple example
of using melt followed by cast that produces a smallish amount of
output about the chicks database. Here's the code:
library(reshape)
names(ChickWeight) <- tolower(names(ChickWeight))
chick_m <- melt(ChickWeight, id=2:4, na.rm=TRUE)
DietResults <- cast(chick_m, diet + chick ~ time)
DietResults
My challenge
2008 Jul 30
1
bug in 'margins' behavior in reshape - cast
according to the documentation of the cast function in the reshape function,
I would expect this bit of code from the examples to calculate marginal
means over only the 'diet' variable.
#Chick weight example
names(ChickWeight) <- tolower(names(ChickWeight))
chick_m <- melt(ChickWeight, id=2:4, na.rm=TRUE)
cast(chick_m, diet + chick ~ time, mean, margins="diet")
But,
2008 Jul 04
1
Calling and running a compiled program inside R
Hi,
I need to use the outputs from a complied program (*.exe program
that is made by some one else) for numerous data sets and use R with the
outputs for some computations. I thought that it would be very
efficient if I can use R from the beginning to the end by calling the
exe program and run it within R, continuing the computations based on
the outputs. Are there any calling function for
2008 Feb 21
2
Unable to create/index a zoo irregular timeseries
In the text file pressione2008.csv I have the following
"Data","MAX","MIN","Note"
"07-01-2008 08:00:00", 135, 90, "Eccessi feste, inizio dieta"
"07-01-2008 18:00:00", 135, 85, ""
"08-01-2008 08:00:00", 125, 75, ""
which is a collection of blood pressure data at different time of the day.
I would
2007 Sep 25
1
Score test in logistic regression in R
Hello,
I am wondering if R has any ways to conduct the score test in logistic
regression?
Could you let me know please?
Thanks,
Insu
--------------------------------------------------
This e-mail and any files transmitted with it may contain privileged or confidential information.
It is solely for use by the individual for whom it is intended, even if addressed incorrectly.
If you
2005 May 19
2
R matrix sorting question
Dear there,
I am trying to do the following stuff. Could you let me know how to do
it efficiently?
> aaa
[,1] [,2]
[1,] 1 -0.2
[2,] 3 0.8
[3,] 4 0.3
[4,] 5 0.2
[5,] 7 0.9
And I would like to sort the matrix by column 2 (and accordingly column 1
sorted as well).
The desired matrix will be
1 -0.2
5 0.2
4 0.3
3 0.8
7 0.9
If using Excel or SAS, I can
2008 Nov 20
1
About continuity correction option in the mantelhaen.test function.
Hello,
I was using the mantelhaen.test function (2x2 J tables for
conditional independence testing). I noticed that the option for the
continuity correction (correction=T or correction=F) sometimes made a
difference while sometimes it did give the same results regardless of
correction=T or correction=F.
Does the continuity correction apply only in certain cases or in
certain strata with some
2005 Jul 21
4
Executable 'username map'
Hi,
I currently manage an environment where my Unix and Windows usernames are
defined, but different. So, I must use a username map. But I have several Samba
servers (one for each NFS package) and I must maintain all these username map
files. As we want everybody to map the same way on every Samba servers in a NIS
domain, we added the 'Windows user' information to the NIS
2006 Dec 09
1
OCFS and LVM2
Hi Everyboy !
I read that LVM2 is not cluster aware (specially with OCFS2) from different
post on internet forum... If it's true, could someone could confirm this
information and point me where i can find this affirmation in documentation
?
I do some test with OCFS2 on LVM2 and it's seems to run correctly , so i
have some interrogation about this fact !
If it's true that LVM2 are
2006 Nov 27
1
copying files from ocfs to ext3
Hi, using ocfs-2.4.9-e-smp-1.0.12-1 on Redhat 3 U4
Trying to copy files from an ocfs volume to an ext3 volume is very very slow
- talking a couple of minutes for a 100Mb file.
same happens if I use o-direct or not, dd exhibits the same behaviour
ocfs is in the updatedb.conf and both filesystems are in the PRUNEPATHS line
in the same file (a reboot was done after the changes were made just to