Displaying 20 results from an estimated 600 matches similar to: "Package zelig"
2012 Feb 09
3
how to exclude rows with not-connected coalitions
Dear all,
I have question but cannot explain without providing some context first:
I want to calculate how many policy-connected coalitions between 7 parties are possible. I have positions on an one-dimensional scale for each party and I have sorted the parties on the positions (it is sorted from extreme left to extreme right, hence using a left-right scale). A policy-connected coalition
2013 Mar 05
2
Zelig package: Coxph model problems
Hi,
I'm having problems with the Zelig package - when using
the below R displays the follwing message (I'm running R
i386 2.15.3 for Windows and have updated all the Zelig
packages):
z.out<-zelig(Surv(psurv2, pcens2) ~ ren_sup3 + age,
data=data_urgent, model="coxph")
** The model "coxph" is not available with the currently
loaded packages,
** and is not an
2012 Jun 15
1
help in sentDetect() fuction
hello,
I am using the following code
>s<-"I am very happy, excited, and optimistic.I am very scared, annoyed, and
irritated.Iraq?s political crisis entered its second week one step closer to
the potential.dissolution of the government, with a call for elections by a
vital coalition partner and a suicide attack that extended the spate of
violence. that has followed the withdrawal.of
2007 May 26
1
How to get the "Naive SE" of coefficients from the zelig output
Dear R-user:
After the fitting the Tobit model using zelig, if I use the following command then I can get the regression coefficents:
beta=coefficients(il6.out)
> beta
(Intercept) apache
4.7826 0.9655
How may I extract the "Naive SE" from the following output please?
> summary(il6w.out)
Call:
zelig(formula = il6.data$il6 ~ il6.data$apache, model =
2007 Nov 01
1
Zelig and the "blogit" model
Hi Folks,
According to the PDF file blogit.pdf in the Zelig
documentation:
"Use the bivariate logistic regression model ["blogit"]
if you have two binary dependent variables (Y1,Y2), and
and wish to model them jointly as a function of some
explanatory variables. Each pair of dependent variables
(Yi1,Yi2) has four potential outcomes, (Yi1=1,Yi2=1),
(Yi1=1,Yi2=0),
2010 Mar 29
1
Question about 'logit' and 'mlogit' in Zelig
I'm running a multinomial logit in R using the Zelig packages. According to str(trade962a), my dependent variable is a factor with three levels. When I run the multinomial logit I get an error message. However, when I run 'model=logit' it works fine. any ideas on whats wrong?
## MULTINOMIAL LOGIT
anes96two <- zelig(trade962a ~ age962 + education962 + personal962 + economy962 +
2016 Apr 18
3
Sum of Numeric Values in a DF Column
Hi,
I request help with the following:
INPUT: A data frame where column "Lower" is a character containing numeric
values (different count or occurrences of numeric values in each row,
mostly 2)
> dput(dd)
structure(list(State = c("Alabama", "Alaska", "Arizona", "Arkansas",
"California"), Lower = c("R 72?33",
2010 Nov 04
3
postForm() in RCurl and library RHTMLForms
Hi RUsers,
Suppose I want to see the data on the website
url <- "http://www.nseindia.com/content/indices/ind_histvalues.htm"
for the index "S&P CNX NIFTY" for
dates "FromDate"="01-11-2010","ToDate"="02-11-2010"
then read the html table from the page using readHTMLtable()
I am using this code
webpage <-
2010 May 10
3
scope of a function + lazy evaluation
Hey guys,
I have a doubt here , It is something simple I guess, what am I missing out
here ??
f <- function(y) function() y
tmp <- vector("list", 5)
for (i in 1:5) tmp[[i]] <- f(i)
tmp[[1]]() # returns 5;
z <- f(6)
tmp[[1]]() # still returns 5; it should return 6 "ideally" right ???
Even if I dont evaluate the function tmp[[1]] before i.e I do
rm(list=ls())
f
2016 Apr 18
0
Sum of Numeric Values in a DF Column
## Continuing with your data
AA <- stringr::str_extract_all(dd[[2]],"[[:digit:]]+")
BB <- lapply(AA, as.numeric)
## I think you are looking for one of the following two expressions
sum(unlist(BB))
sapply(BB, sum)
On Mon, Apr 18, 2016 at 12:48 PM, Burhan ul haq <ulhaqz at gmail.com> wrote:
> Hi,
>
> I request help with the following:
>
> INPUT: A data frame
2016 Apr 18
2
Sum of Numeric Values in a DF Column
... and here is a non-dplyr rsolution:
> z <-gsub("[^[:digit:]]"," ",dd$Lower)
> sapply(strsplit(z," +"),function(x)sum(as.numeric(x),na.rm=TRUE))
[1] 105 67 60 100 80
Cheers,
Bert
Bert Gunter
"The trouble with having an open mind is that people keep coming along
and sticking things into it."
-- Opus (aka Berkeley Breathed in his "Bloom
2010 Jul 13
2
Zoo - bug ???
Hi folks,
I am confused whether the following is a bug or it is fine
Here is the explanation
a <- zoo(c(NA,1:9),1:10)
Now If I do
rollapply(a,FUN=mean,width=3,align="right")
I get
> rollapply(a,FUN=mean,width=3,align="right")
3 4 5 6 7 8 9 10
NA NA NA NA NA NA NA NA
But I shouldn't be getting NA right ? i.e for index 10 I should get
(1/3)*(9+8+7)
2016 Apr 18
0
Sum of Numeric Values in a DF Column
... and a slightly more efficient non-dplyr 1-liner:
> sapply(strsplit(dd$Lower,"[^[:digit:]]"),
function(x)sum(as.numeric(x), na.rm=TRUE))
[1] 105 67 60 100 80
Cheers,
Bert
Bert Gunter
"The trouble with having 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
2010 Feb 26
4
ClientAliveInterval
Hi,
I am having some trouble with the ClientAliveInterval server setting. My
(C++) application fails to start an SSH channel to an OpensSSH server within
this time-out period if it doesn't reply correctly to this 'keep-alive'
no-op that is sent by the server. How is this no-op handled? I am using the
libssh client library, and I could find no references on how to handle this.
2003 Dec 23
4
getting rid of "permission denied" partial transfer errors
Hi,
I am currently setting up a backup script for the /home directory of a
server. I send all the files on a remote machine through LAN connection
using rsync to optimize bandwidth usage.
The script is run as root on the server by a cron job but rsync connects
to the remote machine as a normal user via an ssh key certificate. This
leads to many "permission denied" errors, as the
2009 Feb 19
0
Zelig method setx()
Hello,
I am attempting to "automate" a Bayesian normal linear regression
using Zelig. Basically, I have a list containing several zelig()
objects, each having a different formula, same data set, and same
model (normal.bayes).
My problem lies in the setx() method, where I am setting a numeric
parameter to a value other than the mean. This is straightforward if
I input the parameters
2011 Dec 16
0
Error constructing probabilities in Zelig
I've run an ordered logistic regression model in R with Zelig and am
looking to calculate predicted probabilities. Zelig has a series of simple
one line commands to generate the information I want on first differences
and so forth. Unfortunately, I keep getting an error when running the zelig
function and was wondering if there was a quick alternative for generating
predicted probabilities for
2010 Dec 21
0
"variable lengths differ (found for '(weights)')" error in Zelig library
Dear R users,
I am trying to estimate to estimate the average treatmen effect on the
treated (ATT) using first the MatchIt software to weight the data set and,
after this, the Zelig software as shown in Ho et al. (2007). See here for an
explanation of how to apply this technique in R:
http://imai.princeton.edu/research/files/matchit.pdf
I encounter a slight problem when I apply the weights that
2011 Jul 06
0
matching, treatment effect-ATT and Zelig package
Hi there,
I'm wondering what Zelig in the following situation (code below) actually does. Is this considered as a so called regression adjustment after the propensity score matching?
library(MatchIt)
library(Zelig)
data(lalonde)
re78 represents the outcome variable
1. With Zelig
m.out <- matchit(treat ~ age + educ + black + hispan + married + nodegree + re74 + re75, data = lalonde)
2011 Jan 25
0
Problem with matchit() and zelig()
Dear all,
Does anybody know why the following code returns an error message?
>library(MatchIt)
>library(Zelig)
>data(lalonde)
>
>m.out1<-matchit(treat~age+educ+black+hispan+nodegree+married
+re74+re75, method="full", data=lalonde)
>
>z.out1<-zelig(re78~age+educ+black+hispan+nodegree+married+re74+re75,
data=match.data(m.out1, "control"),