search for: quintile

Displaying 20 results from an estimated 21 matches for "quintile".

Did you mean: quantile
2010 Apr 07
0
Help with manipulation of svytotal output
...would then like to delete all the headings. svyby(~agestrata, ~cbc1+fruitveg4, dudleyls1rake.male,na.rm=TRUE, svytotal, keep.var=FALSE, keep.names=FALSE) cbc1 fruitveg4 statistic.agestrata18-24 statistic.agestrata25-34 statistic.agestrata35-44 statistic.agestrata45-54 1 Quintile 1 - Most deprived At least 5 portions a day 130.31565 535.3994 725.5864 464.61695 2 Quintile 2 At least 5 portions a day 116.25985 971.5924...
2012 Apr 20
1
Package "demography" - calculating quintiles of survival probabilities
Hi, I am using the package "demography" from Rob Hyndman for the Lee-Carter-Model. It is an amazing powerful tool but I am struggling with one issue: *I want to compute different quintiles for the cumulative survival probability derived from the Lee-Carter-Forecast (e.g. the 50%-quintile, 75%-quintile and 99%-quintile) for the next 10 years. * I am sure the package possess this functionality but I didn't find any way to calculate quintile values. Hope you can help me! Tha...
2009 Jan 19
1
conditional weighted quintiles
Dear All, I am economist and working on poverty / income inequality. I need descriptive statitics like the ratio of education expentitures between different income quintiles where each household has a different weight. After a bit of google search I found 'Hmisc' and 'quantreg' libraries for weighted quantiles. The problem is that these packages give me only weighted quintiles; but what I need is conditional weighted quintiles. The below example illus...
2011 May 08
2
help with mysql and R: partitioning by quintile
...0 u1,6,130 . u2,1,23 . . where "frequency" is the number of times a music track is played by a "userid" I need to turn my 'frequency' table into a rating table (it's for a recommender system). So, for each user, I need to categorise the frequency of tracks played by quintile so that each particular track can have 5 ratings (1-5), with the ratings allocated as follows: inter-quintile range 100-80% = rating 5, inter-quintile range 80-60% = rating 4, ..., inter-quintile range 20-0% = rating 1) Hence, I need to create a table with fields userid,track,rating: u1,1,1 u1,2...
2013 Apr 06
1
Creating quintiles on monthly basis
Hi, I am trying in R to indicate in which quintile a value of a variable is for every month of my data frame in this case based on volatility. For each month I want to know for each stock if it is in the most volatile quintile of if it is in one of the others. So far I have come up with the following function (see below). Unfortunately, the functi...
2011 Nov 18
1
R: writing data from one matrix into another with keeping NA's
Hi, I am looking to build even quintiles for a set of data. I managed to get it done, but I would like to know if there is a more direct way to write the data from my loop output x in the bottom of the code into the "empty" matrix p1, which I filled with NA''s. The way I am doing it at the moment is, more or less adding...
2004 Oct 20
1
Drawing multiple line plots
...115 0.123 0.115 0.166 0.000 MMA 0.091 0.107 0.115 0.142 0.179 0.000 DMA 0.126 0.103 0.126 0.129 0.142 0.031 The numbers in the dataframe indicate values of a continuous variable INMET (indicating ratio of inorganic arsenic vesus methylated arsenic species) for the respective quintiles of variables INAS, MMA, and DMA; "lowest" through "highest" indicate quintile levels of INAS, MMA, and DMA. INAS, MMA, and DMA are discrete ordinal variables (factors, each variable has following levels: lowest, ..., highest). Significance indicates significance levels. >...
2010 Sep 07
2
Plotting longitudinal data
...ot against the fourth which is the date. First I 'aggregate' the patient_ids: id<-unique(dat$patient_id) Then I try (and fail) to create a loop, that is supposed to plot the data: for(i in 1:8480){patient_id==id[i]plot(date,value)} What might be wrong? And how could I only plot eg quintiles for the ones that go down fastest? Thanks, Jukka
2007 Mar 12
1
replicating SAS's "proc rank" procedure
Hello- I wonder if there's a way to replicate SAS rank procedure where it ranks a variable by a certain number of groups. For example, it's very easy to calculate quintile rank in SAS, but I couldn't find the similar function in R. Does anyone know how to do this? Thanks. -- View this message in context: http://www.nabble.com/replicating-SAS%27s-%22proc-rank%22-procedure-tf3392910.html#a9445440 Sent from the R help mailing list archive at Nabble.com.
2012 May 10
0
Coloring subsets of points of a strip chart by quantiles
Hello All, I am trying to color five subsets of points in a series of vertical strip charts by quintiles using the quantile function, but I have not been able to do this successfully, nor have I been able to find an example of this online. I would like to have the "E1", "E2", and "E3" columns plotted on a single plot (containing the three strip charts). I am overlaying...
2013 Mar 26
2
GAM model with interactions between continuous variables and factors
...int 18 21 21 23 21 22 26 18 27 21 ... $ time : int 3 3 3 3 3 3 3 3 3 3 ... $ child_mortality : num 0.232 0.232 0.232 0.232 0.232 ... $ democracy : Factor w/ 1 level "dictatorship": 1 1 1 1 1 1 1 1 1 1 ... $ wealth : Factor w/ 5 levels "Lowest quintile",..: 2 4 1 4 5 1 4 1 4 5 ... $ birth_year : int 1970 1970 1970 1970 1970 1970 1970 1970 1970 1970 ... $ residence : Factor w/ 2 levels "Rural","Urban": 1 1 1 1 2 1 1 1 1 2 ... $ birth_order : int 1 2 2 5 1 1 3 1 2 2 ... $ maternal_educ : Facto...
2020 Nov 12
1
Propensity Score Matching
...culo he leído que el PSM se puede utilizar como un elemento de clasificación y por tanto de homogeneización. Mi intención es aplicar el PSM a un análisis de supervivencia. En este sentido mi hipótesis es que una variable ?x? tanto en su versión cuantitativa como categorizada a terciles,cuartiles o quintiles influye sobre la supervivencia de los sujetos. Esto entiendo que puedo resolverlo con un análisis de supervivencia y posteriormente con una regresión de Cox. Este método seria valido desde el punto de vista estadístico si bien desde el punto de vista biológico podría tener alguna duda de interpret...
2020 Nov 10
0
Help propensity score
...culo he leído que el PSM se puede utilizar como un elemento de clasificación y por tanto de homogeneización. Mi intención es aplicar el PSM a un análisis de supervivencia. En este sentido mi hipótesis es que una variable ?x? tanto en su versión cuantitativa como categorizada a terciles,cuartiles o quintiles influye sobre la supervivencia de los sujetos. Esto entiendo que puedo resolverlo con un análisis de supervivencia y posteriormente con una regresión de Cox. Este método seria valido desde el punto de vista estadístico si bien desde el punto de vista biológico podría tener alguna duda de interpret...
2005 Jul 12
0
transition matrix and discretized data
...two-comun data frame. column 1 is the period-one individuals' earnings and column two is the period-two. n <- nrow(X) #12000 sim <- runif(n, -.0001, .0001) X <- X + sim q <- 10 # in order to compute deciles. it could be quintiles, quartiles, whatever p <- seq(0,1,1/q) f.x <- quantile(X[,1], p, names=F) f.y <- quantile(X[,2], p, names=F) f.x[1] <- 0; f.y[1] <- 0 a <- cut(X[,1], f.x, right=T) b <- cut(X[,2], f.y, right=T)...
2009 Apr 16
0
points geodata {geoR}
I used points graphic (geoR) in this way: points(zn,pt.divide=c("quintiles"), main="Location map of Zn",lambda=1,col="gray",yl="coord y",xl="coord x",x.leg=0. 3, y.leg=5.5,dig.leg=2,cex.min=0.5,cex.max=1,) Can I reduce legend characters (a sort of cex)?
2009 Oct 20
1
Dummy variables or factors?
Dear R-people, I am analyzing epidemiological data using GLMM using the lmer package. I usually explore the assumption of linearity of continuous variables in the logit of the outcome by creating 4 categories of the variable, performing a bivariate logistic regression, and then plotting the coefficients of each category against their mid points. That gives me a pretty good idea about the
2008 Aug 02
1
problem with nested loop for regression
...(rollstart):maxrow) #test loop - works { #extract the relevant timeframe... dslice<-PmatTS[(i-period):i,] #slicing past 100 days dslicets<-ts(dslice) #operating on sliced data... Pmin<-rollapply(dslicets, wind, by=wind, min, na.rm=F) #getting min data at per quintile Pmax<-rollapply(dslicets, wind, by=wind, max, na.rm=F) Pmult<-Pmin*Pmax #calculating product tt<-time(Pmult) for (j in 1:5) #1st nested loop { PmatWt[j,]<-Pmult[j,]*mult_col[j,] } #rolling regression analysis... for (k in 1:maxcol) #2nd nested loop...
2006 Mar 23
1
AIX 5.1 rsync large file
Hello, I have inherited a setup where there are 2 AIX 5.1 systems in 2 separate sites. There are large database files that are backed from each site to the other via rsync. Currently, it is using rsync version 2.5.4. It does it via ssh with the options -avz. This has all been merrily plodding along for some time. There is one file that is over 45 GB, and it started having trouble with that
2003 Sep 25
1
Diamond graphs, again.
Some time ago I was allowed to discuss "Diamond Graphs", and whether they would be useful in R, in this mailing list. The August 2003 issue of The American Statistician has finally arrived here and I have been able to read the article. A number of points of interest arise. 1. The article is "A Diamond-Shaped Equiponderant Graphical Display of the Effects of Two
2010 May 26
3
error "variable names are limited to 256 bytes" when sourcing code
I've written a function that takes some input data output from a simulation model and creates some graphs. It's not very complicated code, and it works perfectly fine if I just run the code as is. But I have converted it into a function so we call it externally, and when I try to source the code to test the function, I get the error message "variable names are limited to 256