similar to: using lapply()

Displaying 20 results from an estimated 4000 matches similar to: "using lapply()"

2008 Oct 03
1
NA's in segmented
I am trying to fit a very simple broken stick model using the package "segmented" but I have hit a roadblock. > str(data) 'data.frame': 18 obs. of 2 variables: $ Bin : num 0.25 0.75 1.25 1.75 2.25 2.75 3.25 3.75 4.25 4.75 ... $ LnFREQ: num 5.06 4.23 3.50 3.47 2.83 ... I fit the lm easily: > fit.lm<-lm(LnFREQ~Bin, data=id07) But I keep getting an error
2006 Aug 11
1
x tick labels - sparse?
Hi, I'm stuck on creating a plot with x tick labels for every Nth tick mark - how is that done? I don't see a simple solution to this in help(plot) or help(par) and what I've tried is not working, eg, the following does not work, although it seems intuitive to me that it should work: x <- seq(-100,1000,25) y <- x * x % find all the x values that are multiples of 100 tmp <-
2010 Sep 03
4
Generation of uniform random numbers
Dear R helpers I have following dataset rate_number = matrix(c(5, 15, 60, 15, 5, 0, 20, 60, 20,0, 10, 20, 40, 20, 10), nrow = 5, ncol = 3) range_mat = matrix(c(6.25, 6.75, 7.25, 8.75, 9.25, 9.75, 8.5, 9, 9.5, 10.5, 11, 11.5, 4.25, 4.75, 5.25, 5.75, 6.25, 6.75), nrow = 6, ncol = 3) > rate_number        [,1]   [,2]   [,3] [1,]    5     0      10 [2,]   15   20      20 [3,]   60   60      40
2007 Dec 08
0
help for segmented package
Hi, I am trying to find m breakpoints of a linear regression model. I used the segmented package. It works fine for small number of predicators and breakpoints.(3 r.v. 3 points). However, my model has 14 variables it even would not work even for just one breakpoints!. The error message is always estimated breakpoints are out of range. Since my problem is time related problem. So I
2008 Aug 07
2
Problems using hetcor (polycor)
Sorry if this post should be long but I tried to give you a piece of my data to reproduce my error message using hetcor: Fehler in result$rho : $ operator is invalid for atomic vectors Zus?tzlich: Warning messages: 1: In polychor(x, y, ML = ML, std.err = std.err) : 1 row with zero marginal removed 2: In polychor(x, y, ML = ML, std.err = std.err) : the table has fewer than 2 rows Error in
2009 Aug 13
1
R code to reproduce (while studying) Bates & Watts 1988
Hi R users, I'm here trying to understand correlated residuals in nonlinear estimation. I'm reading/studying the book Bates, D. M. and D. G. Watts, (1988), /Nonlinear regression analysis and its applications/, Wiley, NY. pages 92-94, trying to reproduce the figures and to find out the code in R to perform the necessary calculations. I also consulted Pinheiro and Bates, but without
2008 Jun 15
1
Help finding the mode and maximum for a specified 'window' of time series data
I am relatively new to R, so apologize up front for my long question, particularly if there is too much or too little information. I have a large time series data set where each subject's behavior was originally coded on .25s intervals for 3min task. I am trying to determine if the findings are different depending on the coding interval (i.e. Compare .25s to 1s to 5s to 10s). I also need to
2010 Oct 29
1
Tukey post hoc comparison (glht?) after 3factorial mixed model (lmer)
Hello, dear R-community. This is a question about TukeyHSD between factor combinations of a Three-Way ANOVA, which is - since it is a multi measure ANOVA - not a simple ANOVA but a Generalised Linear Mixed Model (GLMM), calculated with "lmer". > growth <- groupedData(length~meas|box_id,outer=~spec*comp*water,data=all.spec) > model <-
2010 Aug 30
1
Help With Post-hoc Testing
I am trying to do post-hoc tests associated with a repeated measures analysis with on factor nested within respondents. The factor (SOI) has 17 levels. The overall testing is working fine, but I can''t seem to get the multiple comparisons to work. The first step is to "stack" the data. Then I used "lme" to specify and test the overall model. Finally
2000 Mar 01
0
isoMDS error message!!! (fwd)
uhps!! I forgot to tell you that I'm running R 0.99.0 for windows32 on windows 95 osr2. Thank you very much for the latest R-1.0.0 (even if I don't tried it yet)!!! Andrea Rossetti University of Perugia (Italy) Statistical Science Department. ---------- Forwarded message ---------- Date: Tue, 29 Feb 2000 17:03:51 +0100 (MET) From: Andrea Rossetti <rossetti at markov.stat.unipg.it>
2012 Apr 24
2
Basic matrix manipulation problem
Hello, this forum was very helpful yesterday with a simple question I had on working with tables. What function will I need to use to do the following. Move matrix a: A B C D x 1 2 3 4 y 5 6 7 8 to the mean of B&C and C&D: BC CD x 2.5 3.5 y 6.5 7.5 and then to the mean of B&CB, C&BC, C&CD, and D&CD: AAB BAB
2009 Aug 04
0
Writing a NetCDF file in R
Dear all, I am attempting to convert 10 NetCDF files into a single NetCDF file, due to the data input requirements of a model I hope to use. I am using the ncdf package, version 1.6. The data are global-scale water values, on a monthly basis for 10 years (ie. 120 months of data in total; at present the data are separated by year, with 12 months of data in each file - mrunoff_1986 through to
2009 Aug 05
0
ncdf package problem - put.var.ncdf
Dear all, I am attempting to convert 10 NetCDF files into a single NetCDF file, due to the data input requirements of a model I hope to use. I am using the ncdf package, version 1.6. The data are global-scale water values, on a monthly basis for 10 years (ie. 120 months of data in total; at present the data are separated by year, with 12 months of data in each file - mrunoff_1986 through to
2008 Aug 13
2
mob(party) formula question
I try tu use mob() with my data.frame ('data.frame': 288 obs. of 81 variables; factors, numerics and ordered factors) My response is a binary variable and I should use for modelling a logistic regression (family=binomial). I read in the "MOB" Vignette that I could use a formula like this if I would like to have only partitioning variables apart from the response.
2009 Jun 18
1
recovering the name of a given value in a matrix
Hi all, I've got object *cumsumtab, *where the first row (1,2,3,4,5,6,8,13,14,17,40) are names (actually, categories), and the second row has numeric values. > cumsumtab 1 2 3 4 5 6 8 13 14 17 40 2 4 6 7 9 11 13 14 15 16 17 I'm trying to find a way of finding to which category ( in *names(cumsumtab) * ) belongs a given value (let's say Q1 <- 4.25). So far, I've
2012 Mar 08
0
evaluation of categorical and opinion data
Dear all. I have some data and I seek the way to start their evaluation. The values are from survey of different persons and their opinion about various methods (metoda) and instrument (uzel). I am not sure where to start. I would like to end with combination of method (metoda) and instrument (uzel) sorted to let say three categories according to knowledge (znalost) and influence (vliv)
2013 Jun 15
2
quick Help needed
Hi, i am new to this forum and not sure how it works, I am trying to do deskriptive descripe my data in terms of gender: head(scltotal) pbnr dat dep dys sop ago mis age female messpunkt2 messpunkt1 tage eintrittsjahr 1 10023 1994-02-21 0.75 1.00 0.50 0.50 0.75 35 1 8817 8817 0 1994 2 10023 1994-05-25 0.75 1.00 0.50 0.50 0.75 35 1 8910 8817
2012 Mar 28
1
CI with confint
Hello all, I'm trying to use confint from the MASS package to compute confidence intervals for an nls object. When I plot the results, however, they don't make sense - lines cross over the fitted model or just don't match the data. Code is : Thanks for help dat<-data.frame(a,b) with(dat, plot(a,b)) model<-(nls(b~(1/exp(a*x))*n, data=dat, start=list(x=.001,n=20),
2012 Nov 14
2
aggrete data from combination
Dear R users, A have a dataframe (matrix) with two collumns (plot, and diameter (d)). I want all diameters values for different combination of plots. For example I want all d values for all posible combination, 100C2 (all d values for plot 1 with all d values in the plot 2.......with all d values from plot 1 with all d values from plot 100, ...... with all d values from plot 99 with all d values
2006 Mar 17
1
nlme predict with se?
I am trying to make predictions with se's using a nlme (kew11.nlme below). I get an error indicating levels for a factor are not allowed. I have searched and read Rnews, MEMSS, MASS, R-Help, and other lists in Spanish where I found questions similar to mine but not solution. I do not really care about the method used. Any suggestions to obtain predictions with se's from an nlme