search for: deepankar

Displaying 20 results from an estimated 20 matches for "deepankar".

2007 Apr 23
4
Estimates at each iteration of optim()?
...the estiamtes at each iteration? When I put "control=list(trace=TRUE)" as an option in "optim", I just got the initial and final values of the loglikelihood, number of iterations and whether the routine has converged or not. I need to know the estimate values at each iteration. Deepankar
2007 Oct 24
3
how to loop over a group of variables?
...s named b1, b2, b3, ..., b18. These variables take the value 1, 2 or NA. For each observation, I want to do some computation by looping over the values for the group of variables: b1 to b18. In STATA I would do: forval i=1/18 { --- use b`i' for computation ---- } How can this be done in R? Deepankar
2006 Dec 19
4
Upgrading
...had non-zero exit status in: install.packages(update[, "Package"], instlib, contriburl = contriburl, Do I need to worry about these messages? Do I need to do something else to complete the upgrade process? Another question: what is the command for renaming an existing variable? Thanks. Deepankar
2007 Apr 19
3
Problem installing packages
...ning in install.packages("grid", dep = TRUE) : argument 'lib' is missing: using /usr/local/lib/R/site-library --- Please select a CRAN mirror for use in this session --- Loading Tcl/Tk interface ... done dependency '?grid?' is not available How should I proceed? Deepankar
2007 Nov 06
4
C++ and R interface
...ng of writing the likelihood function in C++ and calling it from within R when using *optim()*. I found that one can call C functions (once they have been compiled) from within R with > dyn.load("file.so") and > .C("function", ...) Can the same be done for C++ code? Deepankar
2007 Apr 18
3
Problems in programming a simple likelihood
...y to run the code, this is what I get: > source("probit.R") Results Warning messages: 1: NA/Inf replaced by maximum positive value 2: NA/Inf replaced by maximum positive value 3: NA/Inf replaced by maximum positive value 4: NA/Inf replaced by maximum positive value Thanks in advance. Deepankar
2011 Oct 09
2
variable name question
...so on. I would like to create the logarithm of per capita for each of the year and could do so in STATA with the following commands: forvalues number = 1990/2009 { gen lpci`number' = log(pci`number') } What would be the corresponding set of commands in R? Thanks a lot in advance. Deepankar
2007 Oct 25
2
the difference between temp and .temp
Hi everyone - This came up within the last day -- Jim's response to Deepankar is pasted below. There are probably lots of reasons, but what is the advantage to using .temp over, say, temp? I often find myself writing temporary objects -- should I use the . preface? What would be the advantages to doing so? Thanks in advance for what will surely be a collection of illumin...
2009 Feb 27
3
question about 3-d plot
...Is there some way to generate a 3-dimensional analogue of this? Can I get a similar simulated scatter plot of points in 3 dimensions where the points are clustered around a plane through the origin where the plane in question is the 3-dimensional analogue of the 45 degree line through the origin? Deepankar [[alternative HTML version deleted]]
2006 Jul 18
2
FW: Large datasets in R
...data increases, this may not hold. Can someone shed light on this? 2. Is What 64-bit versions of R are available at present? Marsh Feldman The University of Rhode Island -----Original Message----- From: Thomas Lumley [mailto:tlumley at u.washington.edu] Sent: Monday, July 17, 2006 3:21 PM To: Deepankar Basu Cc: r-help at stat.math.ethz.ch Subject: Re: [R] Large datasets in R On Mon, 17 Jul 2006, Deepankar Basu wrote: > Hi! > > I am a student of economics and currently do most of my statistical work > using STATA. For various reasons (not least of which is an aversion for > propri...
2007 Oct 26
1
finding birth position
...s. Later, I want to use the information on the position of the male births to compute a likelihood function and do an MLE. Here is how my data frame would look: b1 b2 b3 b4 b5 b6 1 2 1 2 NA NA 2 2 NA NA NA NA 1 2 1 1 1 NA 2 1 NA NA NA NA 1 NA NA NA NA NA 2 1 2 1 NA NA Thanks in advance. Deepankar
2007 May 24
3
Problem with numerical integration and optimization with BFGS
...od (Nelder-Mead) in "optim" instead of BFGS, I do not get any such error message. Since both methods (Nelder-Mead and BFGS) will need to evaluate the integrals, my second question is: why this difference? Below, I am providing the code that I use. Any help will be greatly appreciated. Deepankar ************ CODE START ******************* ############################# # COMPUTING THE LOGLIKELIHOOD # USING NUMERICAL INTEGRALS ############################# LLK <- function(alpha, y) { n <- length(y) lglik <- numeric(n) # TO BE SUMMED LATER TO GET THE LOGLIKELIHOOD...
2024 Jan 11
4
arrow on contour line
Hello, I am drawing contour lines for a function of 2 variables at one level of the value of the function and want to include a small arrow in any direction of increase of the function. Is there some way to do that? Below is an example that creates the contour lines. How do I add one small arrow on each line in the direction of increase of the function (at some central point of the contour
2005 May 05
2
Please help
Hi I am a novice and need to know how to compile glibc (glibc-2.0.6) under an i686, redhat 9, in order to install wine-20050310. The package does not install otherwise. Is there any other alternative (like older package versions, I don't know where to find one).
2006 Dec 19
2
attach and object masking
Hi R users! I am new to R. When I try to attach a simple dataset using the attach() command, I get the following message: > attach(data1) The following object(s) are masked from package:base : write Can someone tell me what this means? (`write' is the name of a variable in the dataset). And, do I need to do do something about this. Thanks.
2010 May 02
1
question about 2SLS
...ndard errors for the parameter estimates? When estimating the model by OLS, I used "NeweyWest" from the package "sandwich" to get HAC standard errors. But, I am not able to use the same method with the results of the "tsls" estimation. Any help would be appreciated. Deepankar [[alternative HTML version deleted]]
2010 May 06
1
question about rolling regressions
...reg2 <- lm(emp.chng~vad.chng+lag.vad.chng+lag.emp.chng, data=d) What I would like to do is to run this regression with a 10 year moving window. So, the first regression should use data from 1948-58, the second from 1949-59 and so on.. the last should use data from 1999-2009. Any suggestions? Deepankar [[alternative HTML version deleted]]
2007 Dec 02
1
speeding up likelihood computation
...y method to speed up the code (by avoiding the for loops or by any other method). I am not providing details of my model or what exactly I am trying to do in each step of the computation below; i would be happy to provide these details if they are deemed necessary for re-working the code. Thanks. Deepankar --------- begin code ----------------------- LLK1 <- function(paramets, data.frame, ...) { # DEFINING THE LOGLIKELIHOOD FUNCTION # paramets IS A 1x27 VECTOR OF PARAMETERS OVER WHICH THE FUNCTION WILL BE MAXIMISED # data.frame IS A DATA FRAME. THE DATA FRAME CONTAINS OBSERVATIONS ON SEVERAL...
2008 May 09
1
data management question
...ions on x for each unit: > tapply(ex1$x, ex1$id, mean) A B C 22.5 32.5 NA But this gives me an NA value for the unit C, which I thought I had already left out. How do I ensure that the computation (in the last step) is limited to only the units I have selected in the first step? Deepankar
2005 May 07
0
Thank You
Thanks for your advice. I am able to compile wine now. -------------- next part -------------- An HTML attachment was scrubbed... URL: http://www.winehq.org/pipermail/wine-users/attachments/20050507/69c21067/attachment.html