similar to: Longitudinal data with non-randomized subjects

Displaying 20 results from an estimated 1000 matches similar to: "Longitudinal data with non-randomized subjects"

2006 Nov 13
3
Profile confidence intervals and LR chi-square test
System: R 2.3.1 on Windows XP machine. I am building a logistic regression model for a sample of 100 cases in dataframe "d", in which there are 3 binary covariates: x1, x2 and x3. ---------------- > summary(d) y x1 x2 x3 0:54 0:50 0:64 0:78 1:46 1:50 1:36 1:22 > fit <- glm(y ~ x1 + x2 + x3, data=d, family=binomial(link=logit)) >
2012 Nov 28
1
Help setting optimization problem to include more constraints
Dear R-helpers, I am struggling with an optimization problem at the moment and decided to write the list looking for some help. I will use a very small example to explain what I would like to. Thanks in advance for your help. We would like to distribute resources from 4 warehouses to 3 destinations. The costs associated are as follows: Destination >From 1 2 3 Total
2005 Jun 14
1
Matrix stability problem
Hello, This is not a problem with R, the calculated results are mathematically correct. This a matrix stability problem. Because of measuring errors, my matrix solution is a bit off. Here is what my equations look like: A11 x11+A12 x12 +A13 x13 = b1 A21 x21+A22 x21 +A23 x23 = b2 A31 x31+A32 x31 +A33 x33 = b3 A is a reading, X is a measured weight, and b is total. The 3 experiments give
2008 May 19
2
Help on nested FOR loops
I am new to more radical programming in R. I am trying to write a nested 'for' loop to produce output that takes subscripts like: for i taking values 1,2,3,4,5 and j taking values 1,2,3 I want to output for a computation using the combination values of i and j a value x like this; i j x 1 1 x11 1 2 x12 1 3 x13 2 1 x21 2 2 x22 2 3 x23 3 1 x31 3 2 x32
2005 Sep 08
5
data manipulation
Dear All, I would be grateful if you can help me. My problem is the following: I have a data set like: ID time X1 X2 1 1 x111 x211 1 2 x112 x212 2 1 x121 x221 2 2 x122 x222 2 3 x123 x223 where X1 and X2 are 2 covariates and "time" is the time of observation and ID indicates the
2006 Mar 11
1
Non-linear Regression : Error in eval(expr, envir, enclos)
Hi.. i have an expression of the form: model1<-nls(y~beta1*(x1+(k1*x2)+(k1*k1*x3)+(k2*x4)+(k2*k1*x5)+(k2*k2*x6)+(k3*x7)+(k3*k4*x8)+(k3*k2*x9)+(k3*k3*x10)+ (k4*x11)+(k4*k1*x12)+(k4*k2*x13)+(k4*k3*x14)+(k4*k4*x15)+(k5*x16)+(k5*k1*x17)+(k5*k2*x18)+(k5*k3*x19)+
2013 Apr 12
2
model frame and formula mismatch in model.matrix()
Hello everyone, I am trying to fit the following model All X. variables are continuous, while the conditions are categoricals. model <- lm(X2
2014 Dec 09
4
[LLVMdev] dmb ishld in AArch64
Hi, I got an optimization problem (O1, O2) regarding memory barrier “dmb ishld” I find in the test/CodeGen/AArch64/intrinsics-memory-barrier.ll , it’s stated that memory access around DMB should not be reordered, but when compiling the Linux kernel, I found load/store in static inline void hlist_add_before_rcu(struct hlist_node *n, struct hlist_node *next) { n->pprev
2014 Dec 10
2
[LLVMdev] dmb ishld in AArch64
I'm using r223407. Switching to a clean built on r223853, it still gives me: ldr x8, [x21,#8] stp x21, x8, [x19] dmb ishst ldr x8, [x19,#8] str x19, [x8] str x19, [x21,#8] Thanks, Chengyu > On Dec 9, 2014, at 6:32 PM, Tim Northover <t.p.northover at gmail.com> wrote: > > On 9 December 2014 at 15:14, Chengyu Song <csong84 at gatech.edu> wrote:
2011 Aug 20
2
a Question regarding glm for linear regression
Hello All, I have a question about glm in R. I would like to fit a model with glm function, I have a vector y (size n) which is my response variable and I have matrix X which is by size (n*f) where f is the number of features or columns. I have about 80 features, and when I fit a model using the following formula,? glmfit = glm(y ~ x1 + x2 + x3 + x4 + x5 + x6 + x7 + x8 + x9 + x10 + x11 + x12 + x13
2009 Jun 24
2
change the height or scale of the y axis
Hallo, All, I have a question about changing the height or scale of the y axis. When I use following two R codes, I can get two plots. Please look at the y axes, the number of indices (x1, x2, ?) on the y axis in the first plot is smaller than that in the second plot, and hence the space between any two indices in the first plot is wider than that in the second plot. As the number of indices
2007 Mar 10
3
long character string problem
Hi All I am having 2 very long character strings (550chars) and I want to put them as expressions together with c(). The problem is that I also get these double-quotes, as seen below in 'fct'. How can I remove these double-quotes? I tried as.name() but it did not work (because of size?). These are creating trouble with subsequent programs, which I tested with strings that for some
2012 May 25
2
Query about creating time sequences
Hi All, I have a query about time based sequences. I know such questions have been asked a lot on forums, but I couldnt find the exact thing that I was looking for. I want to create a time-based sequence which will mimic the trading window AND would span multiple days. Something like below: "2011-01-03 09:15:00 IST" "2011-01-03 09:15:01 IST" .... .... .... "2011-01-03
2011 Dec 15
2
Data Manipulation - make diagonal matrix of each element of a matrix
Dear R list, I have the following data: set.seed(1) n <- 5 # number of subjects tt <- 3 # number of repeated observation per subject numco <- 2 # number of covariates x <- matrix(round(rnorm(n*numco),2), ncol=numco) # the actual covariates x > x [,1] [,2] [1,] -0.63 -0.82 [2,] 0.18 0.49 [3,] -0.84 0.74 [4,] 1.60 0.58 [5,] 0.33 -0.31 I need to form a matrix
2004 May 11
1
calling data frames
Dear List, I've around 1000 *.txt files, I've generate with other software. I've now done the following code (below). My question is how can I automate this (with do.call () ?), so it could be done for all the *.txt files. Thanks in advance, Rog??rio names<- list.files() file <- "BLU_Var_%04d.txt" for(i in 1:1000){
2006 Aug 25
2
horizontal direct product
II am translating some gauss code into R, and gauss has a matrix product function called the horizontal direct product (*~), which is some sort of variant on the Kronecker product. For example if x is 2x2 and y is 2x2 the horizontal direct product, z, of x and y is defined (in the Gauss manual) as: row 1 = x11*y11 x11*y12 x12*y11 x12*y12 row 2 = x21*y21 x21*y22 x22*y21 x22*y22 Or in R
2018 Mar 14
2
truncation/rounding bug with write.csv
I don't see the issue here. It would be helpful if people would report their sessionInfo() when reporting whether or not they see this issue. Mine is > sessionInfo() R version 3.4.3 (2017-11-30) Platform: x86_64-pc-linux-gnu (64-bit) Running under: Arch Linux Matrix products: default BLAS/LAPACK: /usr/lib/libopenblas_haswellp-r0.2.20.so locale: [1] LC_CTYPE=en_US.UTF-8
2010 May 11
1
Help with Names
Hi - a newbie question, if someone can please help.... I want to change X1, X2,,.....to X.1 X.2 etc in the names below. I am using the Principal Component Regression function (pcr) and it seems to want it this way > datap3.pcr <- pcr(water ~ X, 10, data = datap3, Validation ="cv") Error in model.frame.default(formula = water ~ X, data = datap3) : invalid type (list) for
2018 Mar 14
2
truncation/rounding bug with write.csv
To my surprise, I can confirm on Windows 10 using R 3.4.3 . As tail is not recognized by Windows cmd, I replaced with: system('powershell -nologo "& "Get-Content -Path temp.csv -Tail 1') The last line shows only 7 digits after the decimal, whereas the first have 15 digits after the decimal. I agree with Dirk though, 1.6Gb csv files are not the best way to work with
2007 Apr 11
1
Programming Problem (for loop, random # control, 3 dimentional graph)
Dear List, This is just a programming problem which i cannot seem to figure out. I am trying to get a set of power from a test (say, kolmogorov smirnov) out of a distribution (say, G-K distribution) as follows. I am trying to reduce to pain of writing the whole set of data points (p# below) using "for" loop. However, I seem to have some problem in it as the output "M" does not