similar to: subsampling table

Displaying 20 results from an estimated 7000 matches similar to: "subsampling table"

2003 Feb 12
1
Na/NaN error in subsampling script
R-help readers, I''m having a problem with an R script (see below), which regularly generates the error message, Error in start:(start + (sample.length - 1)) : NA/NaN argument , for which I am unsure of the cause. In essence, the script (below) generates the start and end points for random subsamples from along a vector (in reality a transect (of a given length,
2011 May 21
2
unbalanced anova with subsampling (Type III SS)
Hello R-users, I am trying to obtain Type III SS for an ANOVA with subsampling. My design is slightly unbalanced with either 3 or 4 subsamples per replicate. The basic aov model would be: fit <- aov(y~x+Error(subsample)) But this gives Type I SS and not Type III. But, using the drop() option: drop1(fit, test="F") I get an error message: "Error in
2011 Aug 11
1
Subsampling data
*Dear R community* * * *I have two questions on data subsample manipulation. I am starting to use R again after a long brake and feel a bit rusty.* * * *I want to select a subsample of data for males and females separately* * * library(foreign) Datatemp <- read.spss("H:/Skjol/Data/HL/t1and2b.sav", use.value.labels = F) > table(Datatemp$sex) 1 2 3049 3702
2005 Jan 14
5
subsampling
hi, I would like to subsample the array c(1:200) at random into ten subsamples v1,v2,...,v10. I tried with to go progressively like this: > x<-c(1:200) > v1<-sample(x,20) > y<-x[-v1] > v2<-sample(y,20) and then I want to do: >x<-y[-v2] Error: subscript out of bounds.
2011 Feb 06
2
Subsampling out of site*abundance matrix
Hello, How can I randomly sample individuals within a sites from a site (row) X species abundance (column) data frame or matrix? As an example, the matrix "abund2" made below. ##### (sorry, Im a newbie and this is the only way I know to get an example on here) abund1 <- c(150, 300, 0, 360, 150, 300, 0, 240, 150, 0, 60, 0, 150, 0, 540, 0, 0, 300, 0, 240, 300, 300,
2009 Apr 06
3
how to subsample all possible combinations of n species taken 1:n at a time?
Hello I apologise for the length of this entry but please bear with me. In short: I need a way of subsampling communities from all possible communities of n taxa taken 1:n at a time without having to calculate all possible combinations (because this gives me a memory error - using combn() or expand.grid() at least). Does anyone know of a function? Or can you help me edit the combn or
2006 Mar 18
2
extraction - subsets
Hi everybody, let us assume i have the following matrixX and vectorY matrixX <- runif(100) dim(matrixX) <- c(10,10) vectorY <- as.matrix(as.character(seq(1,10))) if I define: subsample<-c("2") i can extract the rows from matriX based on the elements in vectorY which are listed in subsample matrixX[vectorY==subsample] if I define subsample with more than 1 element, such
2012 Aug 16
1
Big Data reading subsample csv
Hello, I'm most grateful for your time to read this. I have a uber size 30GB file of 6 million records and 3000 (mostly categorical data) columns in csv format. I want to bootstrap subsamples for multinomial regression, but it's proving difficult even with my 64GB RAM in my machine and twice that swap file , the process becomes super slow and halts. I'm thinking about generating
2011 Nov 01
1
Subsampling-oversampling from a data frame
If no one has a better solution, split it, take a sample of size X from both and put it back together. hgwelec wrote: > > Dear members, > > Consider the following data frame (first 4 rows shown) > > > age sex class > 15 m low > 20 f high > 15 f low > 10 m low > > in my original data set i have 1200 rows and a class distribution
2008 Sep 16
1
analyze subsample of dataframe
Hi there, I'm dealing with a pretty big dataset (~22,000 entries) with numerous entries for every day over a period of several years. I have a column "judy" (for Julian Day) with 0 beginning on Jan. 1st of every new year (I want to compare tendencies between years). However, in order to control for a leap year (2004), I simply need to subtract 1 from every judy value for the year
2009 Jul 21
1
Subsample points for mclust
Hi all! I have an ordered vector of values. The distribution of these values can be modeled by a sum of Gaussians. So I'm using the package 'mclust' to get the Gaussians's parameters for this 1D distribution. It works very well, but, for input sizes above 100.000 values it starts taking really forever. Unfortunately my dataset has around 4.6M values... My question: is it
2012 Jun 28
2
Size of subsample in ecodist mantel()
What is the size of the boostrapped subsample in ecodist mantel() thanks [[alternative HTML version deleted]]
2010 May 07
3
for loop
Dear list, in the following loop im generating objects of type table. What I would like to do is to put all those objects together in a list (that i called cc).I did this but the result is not what i espect to get: cc=list() d=1 for (i in data) { cc=list(cc,assign(paste("n",d,sep=""),table(i,subsample$vD31NADD))) d=d+1} I know that this won't work properly:
2009 Jun 26
1
Where can I find information on how to subsample a time series?
I suspect I'm looking in the wrong places, so guidance to the relevant documentation would be as welcome as a little code snippet. I have time series data stored in a MySQL database. There is the usual DATE field, along with a double precision number: there are daily values (including only normal working days: Monday through Friday). I actually have to do a couple things here. Because of
2011 Sep 08
1
random sampling but with caveats!
Hi, I wonder if someone can help me. I have built a gam model to predict the presence of cold water corals and am now trying to evaluate my model by splitting my dataset into training/test datasets. In an ideal world I would use the sample() function to randomly select rows of data for me so for example with 936 rows of data in my HH dataset I might say ss <- sample(nrow(HH), size =
2017 Sep 25
2
Sample of a subsample
Hello everybody! I have the following problem: I'd like to select a sample from a subsample in a dataset. Actually, I don't want to select it, but to create a new variable sampleNo that indicates to which sample (one or two) a case belongs to. Lets suppose I have a dataset containing 40 cases: data <- data.frame(var1=seq(1:40), var2=seq(40,1)) The first sample (n=10) I drew like
2013 Jan 18
0
repeat resampling with different subsample sizes
Hi, I'm trying to write a code (see below) to randomly resample measurements of one variable (say here the variable "counts" in the data frame "dat") with different resampled subsample sizes. The code works fine for a single resampled subsample size (in the code below = 10). I then tried to generalize this by writing a function with a loop, where in each loop the function
2012 Jun 14
1
Question about sampling
Dear list I wish to extract from a population genotypized for 10 SNP a subsample of the same population of size n with similar allele frequencies. Essentially i have a matrix of 200 rows (df) like this Name,Condition,rs1385699_X,rs6625163_X,rs962458_X,Rs4658627_1, sample01,Case,1,1,1,-1 sample02,Control,1,1,1,1 sample06,Control,1,-1,1,0 sample10,Case,1,1,1,0 sample11,Control,1,1,1,1
2017 Sep 25
0
Sample of a subsample
For personal aesthetic reasons, I changed the name "data" to "dat". Your code, with a slight modification: set.seed (1357) ## for reproducibility dat <- data.frame(var1=seq(1:40), var2=seq(40,1)) dat$sampleNo <- 0 idx <- sample(seq(1,nrow(dat)), size=10, replace=F) dat[idx,"sampleNo"] <-1 ## yielding > dat var1 var2 sampleNo 1 1 40
2004 Oct 29
1
fitting linear mixed model for incomplete block design
Dear R developers and users: I have the following data, x is the response vaiable, nsample(individual) nested within trt, and subsample nested within nsample, I want to fit trt as fixed effect, and block, nsample(trt) as random effects using lme, is the following coding correct? dat$vgrp <- getGroups(dat, form = ~ 1|trt/nsample, level = 2) ge.lme1 <- lme(fixed=x~trt, data=dat,