search for: sampling

Displaying 20 results from an estimated 6113 matches for "sampling".

2017 Aug 05
1
Nested for loop
...% and 15% of the population (800). From 201-300 take 100 samples that are between 5% and 15% of the population (300). I assume this would require a nested for loop. Does anyone have advice as to how to do this? Thanks for your time. Kirsten ## Mark-Recapture ## Estimate popoulation from repeated sampling ## Population size N <- 400 N ## Vector labeling each item in the population pop <- c(1:N) pop ## Lower and upper bounds of sample size lower.bound <- round(x = .05 * N, digits = 0) lower.bound ## Smallest possible sample size upper.bound <- round(x = .15 * N, digits = 0) upper.boun...
2004 Aug 25
1
brlr function
Hi, I''m trying the brlr function in a penalized logistic regression function. However, I am not sure why I am encountering errors. I hope to seek your advice here. (output below) Thank you! Your help is truly appreciated. Min-Han #No error here, the glm seems to work fine >
2017 Aug 06
1
Nested for loop
Hi Kirsten, I can run your example code but I can't quite follow your division of sampling. Can you restate the the task? Below is what I think you are asking for, but I have the feeling I may be off the mark. Set A: 400 samples, draw 100 in range of 5 to 15 Set B: 800 samples, draw 100 in range of 5 to 15 Set C: 300 samples, draw 100 in range of 5 to 15 Ben > On Aug 5, 2017,...
2017 Aug 06
1
Nested for loop
...show how population affects the estimates. Does this make more sense? Thanks for your time! Kirsten On Sun, Aug 6, 2017 at 3:21 PM Ben Tupper <btupper at bigelow.org> wrote: > Hi Kirsten, > > > > I can run your example code but I can't quite follow your division of > sampling. Can you restate the the task? Below is what I think you are > asking for, but I have the feeling I may be off the mark. > > > > > > Set A: 400 samples, draw 100 in range of 5 to 15 > > > > Set B: 800 samples, draw 100 in range of 5 to 15 > > > > Set C...
2008 May 15
4
Warcraft 3 Problem. sortof.
whenever i try to run warcraft 3 via wine it comes up with a large amount of error messages but still runs... any idea on how to fix these messages? i am running it forcing opengl > > err:ole:CoCreateInstance apartment not initialised > fixme:advapi:SetSecurityInfo stub > fixme:win:EnumDisplayDevicesW ((null),0,0x33f3b8,0x00000000), stub! > fixme:win:EnumDisplayDevicesW
2017 Aug 08
1
Nested for loop
...een 5% >> and 15% of the population (300). >> >> I assume this would require a nested for loop. Does anyone have advice as >> to how to do this? >> >> Thanks for your time. Kirsten >> >> ## Mark-Recapture >> ## Estimate popoulation from repeated sampling >> >> ## Population size >> N <- 400 >> N >> >> ## Vector labeling each item in the population >> pop <- c(1:N) >> pop >> >> ## Lower and upper bounds of sample size >> lower.bound <- round(x = .05 * N, digits = 0) >>...
2017 Aug 19
1
bootstrap subject resampling: resampled subject codes surface as list/vector indices
I'm implementing a custom bootstrap resampling procedure in R. This procedure resamples clusters of data points obtained by different subjects in an experiment. Since the bootstrap samples need to have the same size as the original dataset, `target.set.size`, I select speakers compute their data point contributions to make sure I have a set...
2017 Aug 19
1
bootstrap subject resampling: resampled subject codes surface as list/vector indices
...ng an open mind is that people keep coming along and sticking things into it." -- Opus (aka Berkeley Breathed in his "Bloom County" comic strip ) On Sat, Aug 19, 2017 at 7:39 AM, Aleksander G??wka <aglowka at stanford.edu> wrote: > I'm implementing a custom bootstrap resampling procedure in R. This > procedure resamples clusters of data points obtained by different subjects > in an experiment. Since the bootstrap samples need to have the same size as > the original dataset, `target.set.size`, I select speakers compute their > data point contributions to make s...
2007 Jun 03
8
getting t.test to work with apply()
Hi, I''m interested in using apply() with t.test() on a data.frame. Specifically, I''d like to use apply() to do the following: t.test(raw.sample[1,alive],raw.sample[1,dead]) t.test(raw.sample[2,alive],raw.sample[2,dead]) t.test(raw.sample[3,alive],raw.sample[3,dead]) etc. I tried the following, apply(raw.sample,1,function(x) t.test(raw.sample[,alive],raw.sample[,dead])) but
2011 May 03
8
audiohook.c: Failed to get 160 samples from write factory
Hello, I see a lot of these messages in the debug log : /[May 3 15:47:09] DEBUG[19081] audiohook.c: Failed to get 160 samples from write factory 0xae17e18 [May 3 15:47:09] DEBUG[19081] audiohook.c: Failed to get 160 samples from write factory 0xae17e18 [May 3 15:47:09] DEBUG[19081] audiohook.c: Read factory 0xae173e0 and write factory 0xae17e18 both fail to provide 160 samples [May 3
2012 Feb 12
5
Sample function in R
Hi, Can anyone help me with the sample () in R? If I sample from x, I should get one integer. Can anyone tell me what''s wrong here? > x =1:12 > sample(x) [1] 6.5 And, I cannot get the sample with size = 2 > sample(x, size = 2) Error in sample(x, size = 2) : unused argument(s) (size = 2) > sample(x, 2) [1] 54.16667 Thank you in advance [[alternative HTML version deleted]]
2007 Sep 21
3
Estimate correlation with bootstrap
....sample <- numeric(10) b.sample <- numeric(10) boot.cor.a.b <- numeric(1000) for (i in 1:1000) { for (j in 1:10) { a.sample[j] <- sample(a,1,replace=TRUE) b.sample[j] <- sample(b,1,replace=TRUE) } boot.cor.a.b[i] <- cor(a,b) } The problem here is, that the sampling is independent from each other. So how do I have to change the R-code to get the pairwise sampling mentioned above? I hope you can help me. Sincerely Klein. ________
2008 Aug 28
2
sample consecutive integers efficiently
...me rough code to sample consecutive integers with length according to a vector of lengths #sample space (representing positions) pos<-c(1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20) #sample lengths lengths<-c(2,3,2) From these two vectors I need a vector of sampled positions. the sampling is without replacement, making things tough as the sampled integers need to be consecutive. Im hoping somebody knows a faster way of doing it than I have. ATM its way to slow on large vectors. samplePos<-function(l){ start.pos<-sample(pos,1) end.pos<-start.pos+l-1 posies&lt...
2009 Oct 01
13
Re: How to use Subpopulation data?
Dear Helpers   I have a sample frame and i have sampled from it using three methods and now i want to calculate the statistics but i only get the population parameters.   H <- matrix(rnorm(100, mean=50000, sd=5000)) sampleframe=data.frame(type=c(rep("H",100)),value=c(H)) sampleframe   str=strata(sampleframe,c("type"),size=c(20,), method="srswor")
2009 Apr 28
3
Random Sample with Unique function
Dear R-users I have a dataset of 243 lines with replicate information for 20 different individuals (ID). I would like to randomly sample this dataset 100 times with a selection of unique IDs in each sample. First to create a random sample I have; cc<-read.table(blah.blah.blah) names(cc) [1] "CALL" "CONTEXT" "ORDER" "ID"
2012 Mar 07
10
Sampling problems
...ng to something like setdiff () function to compare my 80% sample to the original dataset and obtain the corresponding 20%, unfortunately setdiff works just for vectors, do you know a similar function for dataframes? Thanks -- View this message in context: http://r.789695.n4.nabble.com/Sampling-problems-tp4453752p4453752.html Sent from the R help mailing list archive at Nabble.com.
2007 Oct 29
0
2 commits - libswfdec/swfdec_audio_event.c test/sound
libswfdec/swfdec_audio_event.c | 3 + test/sound/Makefile.am | 7 ++++ test/sound/crash-0.5.3-no-samples.c | 57 ++++++++++++++++++++++++++++++++++ test/sound/crash-0.5.3-no-samples.swf |binary 4 files changed, 67 insertions(+) New commits: commit 835f7dd6a8a7ea739b437e7721506755fa989ca7 Author: Pekka Lampila <pekka.lampila at
2006 Nov 04
0
traits-0.9.2 - better living through metaprogramming
URLS http://rubyforge.org/projects/codeforpeople/ http://codeforpeople.com/lib/ruby/traits ABOUT traits.rb is set of attr_* like methods on steroids, caffeine, and botox. it encourages better living through meta-programming and uniform access priciples. traits.rb supports smart inheritence of class attributes and a fistful of hooks for
2012 Sep 27
3
Generating an autocorrelated binary variable
Hi R-fellows, I am trying to simulate a multivariate correlated sample via the Gaussian copula method. One variable is a binary variable, that should be autocorrelated. The autocorrelation should be rho = 0.2. Furthermore, the overall probability to get either outcome of the binary variable should be 0.5. Below you can see the R code (I use for simplicity a diagonal matrix in rmvnorm even if it
2006 Nov 04
0
traits-0.10.0
URLS http://rubyforge.org/projects/codeforpeople/ http://codeforpeople.com/lib/ruby/traits INSTALL yes|sudo gem install traits ABOUT traits.rb is set of attr_* like methods on steroids, caffeine, and botox. it encourages better living through meta-programming and uniform access priciples. traits.rb supports smart inheritence of class