Displaying 20 results from an estimated 4000 matches similar to: "repeating rows in R"
2009 Jun 03
2
Create a time interval from a single time variable
I am trying to set up a data set for a survival analysis with time-varying covariates. The data is already in a long format, but does not have a variable to signify the stopping point for the interval. The variable DaysEnrolled is the variable I would like to use to form this interval. This is what I have now:
ID Age DaysEnrolled HAZ WAZ WHZ Food onARV
2006 Aug 06
2
no SID in NTUSER.DAT
hello,
when i do profiles NTUSER.DAT
i see this:
[$$$PROTO.HIV\Software\Policies\Microsoft\SystemCertificates\TrustedPublisher]
[$$$PROTO.HIV\Software\Policies\Microsoft\SystemCertificates]
[$$$PROTO.HIV\Software\Policies\Microsoft]
[$$$PROTO.HIV\Software\Policies]
[$$$PROTO.HIV\Software\SimonTatham\PuTTY\SshHostKeys]
[$$$PROTO.HIV\Software\SimonTatham\PuTTY]
2008 Dec 01
1
Comparing output from linear regression to output from quasipoisson to determine the model that fits best.
R 2.7
Windows XP
I have two model that have been run using exactly the same data, both fit using glm(). One model is a linear regression (gaussian(link = "identity")) the other a quasipoisson(link = "log"). I have log likelihoods from each model. Is there any way I can determine which model is a better fit to the data? anova() does not appear to work as the models have the
2008 Aug 21
1
Advice requested: Best method of coding "time since" repeating event
Hello,
I have a dataset containing approx 1000 events spanning four years (2004.03 to 2008.07). For each event, I'd like to determine the time (in minutes) since the most recent final Wednesday of the month. I've found no obvious solution on the list or online; I think I'll try to use functions in the chron package.
Anyone have any other advice?
Thanks.
M-J
School of Population
2011 May 05
4
Using functions/loops for repetitive commands
I still need to do some repetitive statistical analysis on some outcomes
from a dataset.
Take the following as an example;
id sex hiv age famsize bmi resprate
1 M Pos 23 2 16 15
2 F Neg 24 5 18 14
3 F Pos 56 14 23 24
4 F Pos 67 3 33 31
5 M Neg 34 2 21 23
I want to know if there are statistically detectable differences in all of
the continuous variables in
2013 Apr 25
1
Assigning a variable value based on multiple columns
Hi All,
I'm hoping someone can help me with a relatively simple problem. Take the following dataset:
ID Diabetes ESRD HIV Contact
1 0 0 NA 0
2 1 0 NA 0
3 NA 1 0 0
4 0 NA 0 1
5 1 1 1 0
I want to generate a
2008 Sep 04
1
Binary Tree Testing in "ape" package (a bug?)
Dear all,
I was testing the wonderful package APE.
However upon testing a particular Newick's format
tree - which I think to be a non-binary tree -
it yields different result as expected.
> library(ape)
> tree.hiv <- read.tree(text="(rat,mouse,(human,chimp));")
> is.binary.tree(tree.hiv)
[1] TRUE
Was that a bug in APE package?
- Gundala Viswanath
Jakarta - Indonesia
2018 Jul 23
3
[hivex PATCH] Re-allocating unused blocks before assigning new blocks
Hello Richard
As discussed in the IRC channel, when merging a moderately large reg
file (~35MB) to a hiv file (~118 MB); hivex generates a huge hiv file
(~580 MB). These changes address that by creating a list of unallocated
blocks and reassigning unused blocks. I used
https://github.com/msuhanov/regf/blob/master/Windows%20registry%20file%20format%20specification.md
as a reference for the
2003 Oct 06
1
Installing R in Linux 8.0
I am trying to install R in Linux 8.0 and I downloaded
"R-1.7.1-1.i386.rpm" and did rpm -hiv R-1.7.1-1.i386.rpm
and I am getting the following message:
warning: R-1.7.1-1.i386.rpm: V3 DSA signature: NOKEY, key ID
97d3544e
error: Failed dependencies:
libblas.so.3 is needed by R-1.7.1-1
Then I went and look for libblas (which is a linear algebra
library) that I found in
2011 Jul 06
1
superimposing network graphs
Dear all,
I have a undirected network (g), representing all the sexual relationships that ever existed in a model community.
I also have a directed edgelist (e) which is a subset of the edgelist of g. e represents the transmission pathway of HIV.
Now I would like to superimpose the picture of the sexual relationships with arrows in a different colour, to indicate where in the network HIV was
2013 Apr 05
2
model.frame: object is not a matrix
Over a decade ago there was a problem with model.frame when the variable
names were long:
https://stat.ethz.ch/pipermail/r-help/2002-August/024492.html
I have similar symptoms with R 2.15.3 on Windows 7:
Browse[2]> x <- model.matrix(formula(myform), p$data)
Error in model.frame.default(object, data, xlev = xlev) (from mice.R#601) :
object is not a matrix
My attempt at a work-around
2005 May 24
3
obtaining first and last record for rows with same identifier
I have a dataframe that contains fields such as patid, labdate, labvalue.
The same patid may show up in multiple rows because of lab measurements on
multiple days. Is there a simple way to obtain just the first and last
record for each patient, or do I need to write some code that performs that.
Thanks,
Steven
2010 Jan 17
6
More than on loop??
hello every one,
How to function more than one loop in R? I have the following problem to be
solved with the a method of three loops, can you help me please?
The data is attached with this message.
The data is composed of two parts, cleaved (denoted by ?cleaved?) and non
cleaved (denoted by ?noncleaved?).
? to access to the ith peptide, you can use X$Peptide[i]
? to access to the ith label,
2010 Aug 25
2
find most repeated item from column in dataframe
R users,
I am trying to find some way to find the value of a column that is repeated
the most for each StandID of a dataframe. I have research methods online
and the help page, but have had no success in finding a solution. I have
tried using the table function but it returns items for the whole dataset
and not by the StandID. Any help will be appreciated. Thanks in advance.
R version 2.11.1
2011 Feb 25
1
combining two columns into one column despite NAs
I am trying to combine two columns in a data frame into one column. Some
values in either column are missing, but not in the same row for the two
different columns. Additionally, when both columns in a row contain data,
the data are identical. I want a new column with the identical data or the
data from the column with observed data. For example:
I have
>data
id x y
2009 Feb 08
5
glmmBUGS: logistic regression on proportional data
Hello,
I am trying to run a logistic regression with random effects on
proportional data in glmmBUGS. I am a newcomer to this package, and
wondered if anyone could help me specify the model correctly.
I am trying to specify the response variable, /yseed/, as # of successes
out of total observations... but I suspect that given the error below,
that is not correct. Also, Newsect should be a
2010 Sep 11
3
confidence bands for a quasipoisson glm
Dear all,
I have a quasipoisson glm for which I need confidence bands in a graphic:
gm6 <- glm(num_leaves ~ b_dist_min_new, family = quasipoisson, data = beva)
summary(gm6)
library('VIM')
b_dist_min_new <- as.numeric(prepare(beva$dist_min, scaling="classical", transformation="logarithm")).
My first steps for the solution are following:
range(b_dist_min_new)
2012 Jun 06
3
Sobel's test for mediation and lme4/nlme
Hello,
Any advice or pointers for implementing Sobel's test for mediation in
2-level model setting? For fitting the hierarchical models, I am using
"lme4" but could also revert to "nlme" since it is a relatively simple
varying intercept model and they yield identical estimates. I apologize for
this is an R question with an embedded statistical question.
I noticed that a
2011 Nov 06
2
Correlation analysis
Hi everyone,
I am new to R-project. I did search through the list for my problem but i
can't find it. I am sorry if this question has been asked.
I would like to perform a correlation analysis between a hiv data and gene
expression.
Basically, i have a file that contains: hiv_name, start_position,
end_position, chromosome. I would like to see if these data has anything to
do with the
2003 Nov 08
2
Effects of rounding on regression
Does anyone know of research on the effects of rounding on regression?
e.g., when you ask people "How often have you _______?" you are more
likely to get answers like 100, 200, etc. than 98, 203, etc.
I'm interested in investigating this, but don't want to reinvent the
wheel.
thanks
Peter
Peter L. Flom, PhD
Assistant Director, Statistics and Data Analysis Core
Center for