The command
bsample B
with B > _N
(e.g., if _N = 100., trying to sample more than 100 times with replacement)
yields
resample size must not be greater than number of observations
r(498);
Is there a command that can sample with replacement more than _N times? I realize I could loop through floor( B / _N) times and then once more on the remainder, but I'm hoping there is a compact command.
Also, if your time allows, I'm curious: why is bsample limited in this way? It samples with replacement...why can't it generate a randomly-selected sample that has more observations than the original dataset?
Related Posts with Is there a command that is equivalent to "bsample more than _N"?
Deflate wages with deflator from different fileHello, I need to deflate my wages with a consumer price index which I have in a different file. How…
Access instance, class, or function "own" identifiers within the .class fileIn class programming, is there a way to access an instance's, class's or member function's own ident…
-domin- (SSC): computing time /max. number of independent variablesHi everybody, I am using Stata 16.0 and I am trying to perform dominance analysis using the -domin-…
Problems with stset on long dataHi, I'm trying to stset survival data in long format. I used reshape to convert from wide to long: …
Panel Data - treatment*for group data based on within group characteristicsHello, I am interested in assigning a treatment to a firm if it was domestic (foreign=0) in year 20…
Subscribe to:
Post Comments (Atom)
0 Response to Is there a command that is equivalent to "bsample more than _N"?
Post a Comment