similar to: package plm

Displaying 20 results from an estimated 2000 matches similar to: "package plm"

2002 May 14
2
tapply and empty subsets
I am using tapply to compute means by group, as in > tapply(y, z, mean) 1 2 3 21.00757 20.50031 NA where y is a vector and z a factor with levels 1:3. I would like to get a zero instead of the NA I get when a subset is empty. The problem is that FUN is not applied to empty cells of the ragged array. (Of course I am willing to define a function my.mean that returns
2006 Dec 05
3
Comparing posterior and likelihood estimates for proportions (off topic)
This question is slightly off topic, but I'll use R to try and make it as relevant as possible. I'm working on a problem where I want to compare estimates from a posterior distribution with a uniform prior with those obtained from a frequentist approach. Under these conditions the estimates should agree. Specifically, I am asking the question, "What is the probability that the true
2010 Aug 18
3
libreadline problem
Hello, Recently updated Ubuntu to 10.04, I have installed the r-base and r-base-dev packages from CRAN with sudo apt-get install r-base But now when I want to start R I get the following error: gpetris at definetti:~$ R /usr/lib/R/bin/exec/R: symbol lookup error: /usr/local/lib/libreadline.so.6: undefined symbol: PC Any clue??? Has anybody seen that before? I have tried to reinstall the
2003 Oct 29
1
restarting split.screen
Is there a way of `restarting' split.screen? This is what I am getting: > close.screen() [1] 10 11 12 13 > close.screen(all=TRUE) Error in par(args) : parameter "i" in "mfg" is out of range > graphics.off() > x11() > close.screen() [1] 10 11 12 13 > close.screen(all=TRUE) Error in par(args) : parameter "i" in "mfg" is out of range As
2004 May 12
4
non-interactive call to R (running an R package as a stand-alone application)
Is there a way I can have R automatically execute the commands in a source file without ever having to use R interactively? If so, what arguments should I pass to the UNIX call to R? I need to do this to run several R jobs in parallel. An alternative may be to have R and an R package behave as a stand-alone application that can be called from the UNIX command line. Is there any documentation on
2007 Jan 18
4
Reading contingency tables
I am trying to read an ftable using read.ftable, but I get the following error message: > jobSatTable <- read.ftable("http://definetti.uark.edu/~gpetris/stat5333/jobSatisfaction.dat",skip=2) Error in seek(file, where = 0) : no applicable method for "seek" In addition: Warning messages: 1: no non-missing arguments to max; returning -Inf 2: no non-missing arguments to
2008 Oct 09
2
Two math expressions in plot
Hello! I am trying to put two math expressions in the title of a plot. As you can see below, I can place correctly one expression at a time, but not both. Ideally I would like to have them separated by a comma. Any suggestions? > k <- 1 > n.eff <- c(20, 30) > ### this works > plot(0,0, main = substitute(n == k, list(k = k))) > ### this works > plot(0,0, main =
2012 May 25
1
knitr customization
I am trying to transition from Sweave to knitr, but there are a few things about customization of the appearence of R input and output that I did not get yet. Maybe somebody on the list can help me. In my Sweave presentations I used a slanted font for the R input and a normal font for the output, both in a small font. I also indented everything by an extra 2em. All this was achieved by the
2003 Oct 24
5
how to remove NaN columns ?
How can I remove columns with NaN entries ? Here is my simple example: > data <- read.csv("test.csv") > xdata <- data[3:length(data)] > xs <- lapply(xdata, function(x){(x - mean(x))/sqrt(var(x))}) > x <- data.frame(xs) > x C D E F 1 -0.7071068 NaN -0.7071068 -0.7071068 2 0.7071068 NaN 0.7071068 0.7071068
2004 Feb 06
3
quantile function
I am trying to `cut' a continuous variable into contiguous classes containing approximately an equal number of observations. I thought quantile() was the appropriate function to use in order to find the breakpoints, but I end up with classes of different sizes - see example below. Does anybody have an explanation for that? And what is the `recommended' way of computing what I am looking
2011 Mar 09
4
Help with read.csv
Hello, I have a file that looks like this: Date,Hour,DA_DMD,DMD,DA_RTP,RTP,, 1/1/2006,1,3393.9,3412,76.65,105.04,, 1/1/2006,2,3173.3,3202,69.20,67.67,, 1/1/2006,3,3040.0,3051,69.20,77.67,, 1/1/2006,4,2998.2,2979,67.32,69.10,, 1/1/2006,5,3005.8,2958,65.20,68.34,, where the ',' is the separator and I tried to read it into R, but... > y <- read.csv("Data/Data_tmp.csv",
2009 May 08
1
plm: plm.data vs pdata.frame
Hello, I am trying to use the plm package for panel econometrics. I am just trying to get started and load my data. It seems from most of the sample documentation that I need to use the pdata.frame function to get my data loaded. However, even after installing the "plm" package, my R installation cannot find the function. I am trying to follow the example in plmEN.pdf (
2012 May 09
1
Sweave, beamer and alert within code chunks
Hi all, Using Beamer, in order to highlight a piece of R code I do something like this - note the "\structure" and "\alert" commands: \begin{semiverbatim} > mleOut <- \structure{dlmMLE}(Nile, + parm = c(0.2, 120), # initial values for optimizer + lower = c(1e-7, 0)) \alert<2>{# V must be positive} > mleOut$convergence
2010 Jan 21
2
What is the difference between S and R?
On Thu, Jan 21, 2010 at 9:07 AM, Giovanni Petris <GPetris at uark.edu> wrote: > > I have found a good refernce to be "S Programming" by Venables and > Ripley. I'll take a look at this book. Since S and R are not completely the same, there are delicate differences between S and R, which an S book may be confusing if I want to learn R. One example is Statistical Models
2009 Aug 03
1
plm summary error
Dear "plm"-Package insiders, [I posted the following observation is April already but unfortunately I am not aware of any answers. With the hope that someone found an answer in the mean time, I ask again:] I realized the following difficulty with the summary.plm function (demonstrated with the example from the ?plm documentation). library(plm) data("Produc",
2005 Mar 22
1
Package vignette and build
Hello, I am writing a package called 'DLM' containing a vignette. The vignette contains a chunck with the function call 'library(DLM)'. This worked fine with 'R CMD check DLM', but when it comes to building the package with 'R CMD build DLM' I get the following error message: * creating vignettes ... ERROR Error: chunk 1 Error in library(DLM) : There is no
2009 Apr 25
2
plm Hausman-Taylor model
Dear all- I am have trouble in using the model="ht" option in function plm from the plm library. I am using Package: plm Version: 1.1-1; R version 2.8.1 (2008-12-22) running on a FC-8 linux machine. Here is what I am trying to do: ##---------------------------------------------------------------------------- R> ###Prob 6 Chapter 3 Use R! Applied Econometrics with R (Kleiber
2002 Aug 02
1
Means of Monte Carlo simulated lists
Hello, I am doing simulations, and I generate a list at each iteration (with three component matrices in the example below), saving the results in a list. For example, after two iterations, I have something like > str(sim.theta) List of 2 $ :List of 3 ..$ : num [1:6, 1:4] -3.67 -1.07 -2.99 -18.38 -3.26 ... ..$ : num [1:6, 1:6] -7.56 -3.14 -4.99 1.03 2.79 ... ..$ : num [1:6, 1:4]
2009 Jul 09
2
plm Issues
Hi List I'm having difficulty understanding how plm should work with dynamic formulas. See the commands and output below on a standard data set. Notice that the first summary(plm(...)) call returns the same result as the second (it shouldn't if it actually uses the lagged variable requested). The third call results in error (trying to use diff'ed variable in regression) Other info:
2012 Mar 08
1
Panel models: Fixed effects & random coefficients in plm
Hello, I am using {plm} to estimate panel models. I want to estimate a model that includes fixed effects for time and individual, but has a random individual effect for the coefficient on the independent variable. That is, I would like to estimate the model: Y_it = a_i + a_t + B_i * X_it + e_it Where i denotes individuals, t denotes time, X is my independent variable, and B (beta) is the