similar to: Simulation using parts of density function

Displaying 20 results from an estimated 2000 matches similar to: "Simulation using parts of density function"

2007 May 01
3
simulation
Hello I would like to simulate datasets in the following way: x <- rpois(999, 2000) y <- sum(exp(rgamma(x, scale=2, shape=0.5))) The problem is, that by calling "y" I just get 1 value back and not 999 values. Can anyone help me? Thanks! Brigitte [[alternative HTML version deleted]]
2012 Sep 10
1
usb port issue in 9.1-Prerelease (Possibly Cam related)
Hi Folks, I've facing an intermittent hang with a USB port which seems cam related: Event's that happen are: o USB modem (HUAWEI E220) plugged into PC ugen3.2: <HUA WEI> at usbus3 u3g0: <3G Modem> on usbus3 u3g0: Found 3 ports. umass0: <USB MASS STORAGE> on usbus3 umass0: SCSI over Bulk-Only; quirks = 0x0000 umass0:6:0:-1: Attached to scbus6 umass1: <USB
2012 Mar 16
2
Elegant Code
Hi, Can anyone help to write a more elegant version of my code? I am sure this can be put into a loop but I am having trouble creating the objects b1,b2,b3,...,etc. b1 <- rigamma(50,1,1) theta1 <- rgamma(50,0.5,(1/b1)) sim1 <- rpois(50,theta1) b2 <- rigamma(50,1,1) theta2 <- rgamma(50,0.5,(1/b2)) sim2 <- rpois(50,theta2) b3 <- rigamma(50,1,1) theta3 <-
2007 May 03
0
unscrible pls
On 5/2/07, r-help-request@stat.math.ethz.ch < r-help-request@stat.math.ethz.ch> wrote: > > Send R-help mailing list submissions to > r-help@stat.math.ethz.ch > > To subscribe or unsubscribe via the World Wide Web, visit > https://stat.ethz.ch/mailman/listinfo/r-help > or, via email, send a message with subject or body 'help' to >
2013 Jul 04
1
XHCI umass support breaks between r248085 and r252560 on 9-STABLE
Three different external hard drives (Seagate, Western Digital and noname USB 3.0 enclosure) refused to be recognized as the umass devices. Reverting /usr/src/sys/dev/bsd/controller to r248085, building and loading just xhci module makes drives appear again. Below are snippets from the log in both cases: Non working: Jul 4 14:35:17 twinhead kernel: xhci0: <XHCI (generic) USB 3.0
2006 Apr 12
7
help ith burncd (Input/output error, 6.1-RC, plextor PX-740a)
I have a new system which includes a Plextor PX-740a DVD+-R/RW CD-R/RW drive attached to an Asus A8V-MX motherboard. When I try to use burncd to burn a cd, it writes all of the data, says "fixating CD, please wait.." and then reports burncd: ioctl(CDRIOCFIXATE): Input/output error Oddly enough, the CD seems to be usable. I can successfully burn the same file if I use cdrecord. The
2006 Mar 11
4
Problem with 16-in-1 card reader
My new PC has an internal 16-in-1 card reader connected via USB 2.0. The device is the Techsolo TCR-1640 (http://www.techsolo.de/product/cardreader/tcr_1640/index.php). I boot from a compact flash inserted in it and I can mount and unmount the same CF once the system has booted and has mounted the root partition from my graid3 array. The problem arise when I replace the inserted CF with another
2013 Apr 02
4
Samba4 migration
I have a question ... How can I migrate existing LDAP users ( or schemas) on Ubuntu 10.04.2 to the new Samba4 (Ubuntu 12.04.2) server? Does anyone have an idea? Thanks for support Alex -- View this message in context: http://samba.2283325.n4.nabble.com/Samba4-migration-tp4646168.html Sent from the Samba - General mailing list archive at Nabble.com.
2016 Apr 18
0
R [coding : do not run for every row ]
Dear anonymous, The big mistake in the output might be obvious to you but not to others. Please make clear what the correct output should be or at least what is wrong with the current output. And please DO read the posting guide which asks you not to post in HTML. ir. Thierry Onkelinx Instituut voor natuur- en bosonderzoek / Research Institute for Nature and Forest team Biometrie &
2003 Sep 26
2
performance question
Hi, I am about to write functions for multivariate kernel densitiy estimation with mixed categorical and continuous date (accoring to Jeff Racine and Qi Li), and the leave-one-out window esitmation needs a lot of computation. I am now optimizing the code performance and therefore fhe following questions: As R uses call-by-value for functions, is it computational expensive to pass large matrices
2016 Apr 17
2
R [coding : do not run for every row ]
i have combined all the variables in a matrix, and i wish to conduct a simulation row by row. But i found out the code only works for the every first row after a cycle of nine samples. But after check out the code, i don know where is my mistake... can anyone pls help .... #For gamma disribution with equal skewness 1.5 #to evaluate the same R function on many different sets of data
2016 Apr 18
3
R [coding : do not run for every row ]
Hi, i am sorry, the output should be values between 0 and 0.1 and not supposed to be 1.00, it is because they are type 1 error rate. And now i get output 1.00 for several samples,rhis is no correct. The loop do not run for every row. i do not know where is my mistake. As i use the same concept on normal distribution setup, i get the result. Sent from my phone On Thierry Onkelinx
2016 Apr 18
0
R [coding : do not run for every row ]
Always keep the mailing list in cc. The code runs for each row in the data. However I get the feeling that there is a mismatch between what you think that is in the data and the actual data. ir. Thierry Onkelinx Instituut voor natuur- en bosonderzoek / Research Institute for Nature and Forest team Biometrie & Kwaliteitszorg / team Biometrics & Quality Assurance Kliniekstraat 25 1070
2003 Aug 22
5
HEADSUP: USB da(4) quirks disabled for 4.9 and 5.2
If you have any of the devices listed below, please test with a recent -stable or -current. They will stop working in 4.9 and 5.2 although old behavior can _temporarily_ be enabled by adding "options DA_OLD_QUIRKS" to your kernel config. If I don't hear from anyone, they'll be going away permanently after the releases. -Nate #ifdef DA_OLD_QUIRKS /* Below a list of
2005 Mar 03
2
regression on a matrix
Hi - I am doing a monte carlo experiment that requires to do a linear regression of a matrix of vectors of dependent variables on a fixed set of covariates (one regression per vector). I am wondering if anyone has any idea of how to speed up the computations in R. The code follows: #regression function #Linear regression code qreg <- function(y,x) { X=cbind(1,x) m<-lm.fit(y=y,x=X)
2010 Sep 01
1
Looks like a bug in subsetting of a complicated object
I don't understand what is happening! I have a (large) object sim1, an matrix list with dim c(101,101) where each element is an 3*3 matrix. I am subsetting that with a matrix coo, of dim c(100,2), of unique indices, but the resulting object has length 99, not 100 as expected. Code reproducing the problem follows: library(RandomFields) set.seed(123) sim0 <- GaussRF(x=seq(0, 100, by=1),
2019 Dec 27
2
"simulate" does not include variability in parameter estimation
Hello, All: ????? The default "simulate" method for lm and glm seems to ignore the sampling variance of the parameter estimates;? see the trivial lm and glm examples below.? Both these examples estimate a mean with formula = x~1.? In both cases, the variance of the estimated mean is 1. ??? ??????? * In the lm example with x0 = c(-1, 1), var(x0) = 2, and
2004 Feb 05
5
rgamma question
I was trying to generate random numbers with a gamma distribution. In R the function is: rgamma(n, shape, rate = 1, scale = 1/rate). My question is that if X~gamma(alpha, beta) and I want to generate one random number where do I plug alpha and beta in rgamma? and, what is the meaning and use of rate? Thanks for your attention, Jorge [[alternative HTML version deleted]]
2008 Jul 07
4
Plot Mixtures of Synthetically Generated Gamma Distributions
Hi, I have the following vector which is created from 3 distinct distribution (three components) of gamma: x=c(rgamma(30,shape=.2,scale=14),rgamma(30,shape=12,scale=10),rgamma(30,shape=5,scale=6)) I want to plot the density curve of X, in a way that it shows a distinct 3 curves that represent each component. How can I do that? I tried this but doesn't work: lines(density(x)) Please
2005 Jul 27
7
gamma distribution
Hi R Users This is a code I wrote and just want to confirm if the first 1000 values are raw gamma (z) and the next 1000 values are transformed gamma (k) or not. As I get 2000 rows once I import into excel, the p - values beyond 1000 dont look that good, they are very high. -- sink("a1.txt"); for (i in 1:1000) { x<-rgamma(10, 2.5, scale = 10) y<-rgamma(10, 2.5, scale = 10)