Displaying 20 results from an estimated 246 matches for "out1".
Did you mean:
out
2012 Jul 11
2
help with merging 2 data frames
...0,400),e2=c(101,201,101,201,301,401,301,401))
(desired)
# In other words, I want column e1 and e2 entries from data frame y to
be repeated based on matching of column a from x and columns a2 and
then a3 from y.
# I am trying step-by-step - first I am using column a2 from data
frame y for merging:
out1<-merge(x,y[-2],by.x=c("a","b"),by.y=c("a2","b"),all.x=T,all.y=F)
(out1) # looking good - half of the job is done
# Step2 - does not work
# next line produces columns e1 and e2 twice (in real life I have tons
of columns like e1 and e2):
merge(out1,y[-1]...
2010 Dec 21
0
"variable lengths differ (found for '(weights)')" error in Zelig library
...ust
be aware that the quantity of interest may change during the matching
procedure as some
control units may be dropped.)"
The following code is for the "lalonde" data set, where I get an error
message in the end:
> library(Zelig)
> library(MatchIt)
> data(lalonde)
> m.out1 = matchit(treat ~ age + educ + black + hispan + nodegree + married
+ re74 + re75, method = "subclass", subclass=6, data = lalonde)
> z.out1 = zelig(re78 ~ age + educ + black + hispan + nodegree + married +
re74 + re75, data = match.data(m.out1, "control"), model = "ls&qu...
2011 Mar 18
1
help please: put output into dataframe
...data, though I have a large number of variables
var1 <- rnorm(500, 10,4)
var2 <- rnorm(500, 20, 8)
var3 <- rnorm(500, 30, 18)
var4 <- rnorm(500, 40, 20)
datafr1 <- data.frame(var1, var2, var3, var4)
# my unsuccessful codes
nvar <- ncol(datafr1)
for (i in 1:nvar) {
out1 <- NULL
out2 <- NULL
medianx <- median(getdata[,i], na.rm = TRUE)
show(madx <- mad(getdata[,i], na.rm = TRUE))
MD1 <- c(medianx + 2*madx)
MD2 <- c(medianx - 2*madx)
out1[i] <- which(getdata[,i]...
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"), model="ls" , weights="weights" )
>
>x....
2009 Feb 18
2
understanding how R determines numbers and characters when creating a data frame
...can't the character data be converted to numeric data using the fix command?
### Example 1 #############
data(iris)
obsnum<-NULL
results<-NULL
for(s in unique(as.character(iris$Species))){
temp1<-iris[iris$Species==s,]
obsnum<-length(unique(temp1$Sepal.Length)) # a number
out1<-cbind(species=as.character(paste(s)),obsnum) # number converted to
character
results<-rbind(out1,results)
}
results
#fix(results) # cannot convert obsnum to numeric using fix
####################################
******Question for example 2
Why does adding the data.frame command...
2013 Nov 15
1
optimization
...ta.frame(k,x1,x2)
freg<-function(y,x1,x2){
reg<- rlm(y ~ x1 + x2 , data=x)
return(reg)
}
func <- function(x1,x2,b){
fit<-freg(y,x1,x2)
b<-c(coef(fit))
dv<-1+ b[2]*x2^b[3]
dv1<-b[2]*x2^b[3]*log(x2)
out <- ( x1/(1+ b[2]*x2^b[3]))
out1<- c(-x1*x2^b[3]/dv^2,-x1* dv1/dv^2)
return(list( out,out1))
}>
optim(par=c(b[2],b[3]), fn=out, gr =out1,
method = c("BFGS"),
lower = -Inf, upper = Inf,
control = list(), hessian = T)
can someone help me try running this code because i try many...
2015 Dec 01
3
[PATCH 3/6] Input: Update vmmouse.c to use the common VMW_PORT macros
...t;psmouse.h"
>> > #include "vmmouse.h"
>> > @@ -84,21 +85,12 @@ struct vmmouse_data {
>> > * implementing the vmmouse protocol. Should never execute on
>> > * bare metal hardware.
>> > */
>> > -#define VMMOUSE_CMD(cmd, in1, out1, out2, out3, out4) \
>> > -({ \
>> > - unsigned long __dummy1, __dummy2; \
>> > - __asm__ __volatile__ ("inl %%dx" : \
>> > - "=a"(out1),...
2015 Dec 01
3
[PATCH 3/6] Input: Update vmmouse.c to use the common VMW_PORT macros
...t;psmouse.h"
>> > #include "vmmouse.h"
>> > @@ -84,21 +85,12 @@ struct vmmouse_data {
>> > * implementing the vmmouse protocol. Should never execute on
>> > * bare metal hardware.
>> > */
>> > -#define VMMOUSE_CMD(cmd, in1, out1, out2, out3, out4) \
>> > -({ \
>> > - unsigned long __dummy1, __dummy2; \
>> > - __asm__ __volatile__ ("inl %%dx" : \
>> > - "=a"(out1),...
2015 Dec 01
2
[PATCH 3/6] Input: Update vmmouse.c to use the common VMW_PORT macros
...nclude <asm/vmware.h>
>
> #include "psmouse.h"
> #include "vmmouse.h"
> @@ -84,21 +85,12 @@ struct vmmouse_data {
> * implementing the vmmouse protocol. Should never execute on
> * bare metal hardware.
> */
> -#define VMMOUSE_CMD(cmd, in1, out1, out2, out3, out4) \
> -({ \
> - unsigned long __dummy1, __dummy2; \
> - __asm__ __volatile__ ("inl %%dx" : \
> - "=a"(out1), \
> - "=b"(out2), \
> - "=c"(out3), \
> - "=d"(out4), \
> - "=S"...
2015 Dec 01
2
[PATCH 3/6] Input: Update vmmouse.c to use the common VMW_PORT macros
...nclude <asm/vmware.h>
>
> #include "psmouse.h"
> #include "vmmouse.h"
> @@ -84,21 +85,12 @@ struct vmmouse_data {
> * implementing the vmmouse protocol. Should never execute on
> * bare metal hardware.
> */
> -#define VMMOUSE_CMD(cmd, in1, out1, out2, out3, out4) \
> -({ \
> - unsigned long __dummy1, __dummy2; \
> - __asm__ __volatile__ ("inl %%dx" : \
> - "=a"(out1), \
> - "=b"(out2), \
> - "=c"(out3), \
> - "=d"(out4), \
> - "=S"...
2008 Feb 27
2
Sweave produces gibberish instead of apostrophe in pdf
...utput in the "Signif. codes"
line:
\documentclass[a4paper,10pt]{article}
\title{Spam}
\author{F. Bar}
\begin{document}
<<reg>>=
n <- 50
x <- seq(1, n)
a.true <- 3
b.true <- 1.5
y.true <- a.true + b.true * x
s.true <- 17.3
y <- y.true + s.true * rnorm(n)
out1 <- lm(y ~ x)
summary(out1)
@
\end{document}
And the resulting .tex file:
\documentclass[a4paper,10pt]{article}
\title{Spam}
\author{F. Bar}
\usepackage{Sweave}
\begin{document}
\begin{Schunk}
\begin{Sinput}
> n <- 50
> x <- seq(1, n)
> a.true <- 3
> b.true <- 1.5...
2015 Dec 02
3
[PATCH 3/6] Input: Update vmmouse.c to use the common VMW_PORT macros
...Tue, Dec 01, 2015 at 02:45:27PM -0800, Dmitry Torokhov wrote:
> > On Tue, Dec 1, 2015 at 2:32 PM, Sinclair Yeh <syeh at vmware.com> wrote:
> > > Hi,
> > >
>
> <snip>
>
> > >> > */
> > >> > -#define VMMOUSE_CMD(cmd, in1, out1, out2, out3, out4) \
> > >> > -({ \
> > >> > - unsigned long __dummy1, __dummy2; \
> > >> > - __asm__ __volatile__ ("inl %%dx" : \
> > >> > -...
2015 Dec 02
3
[PATCH 3/6] Input: Update vmmouse.c to use the common VMW_PORT macros
...Tue, Dec 01, 2015 at 02:45:27PM -0800, Dmitry Torokhov wrote:
> > On Tue, Dec 1, 2015 at 2:32 PM, Sinclair Yeh <syeh at vmware.com> wrote:
> > > Hi,
> > >
>
> <snip>
>
> > >> > */
> > >> > -#define VMMOUSE_CMD(cmd, in1, out1, out2, out3, out4) \
> > >> > -({ \
> > >> > - unsigned long __dummy1, __dummy2; \
> > >> > - __asm__ __volatile__ ("inl %%dx" : \
> > >> > -...
2012 Apr 09
3
For loops
Hi,
I am having trouble with syntax for a for loop. Here is what I am trying to
do.
class=c(rep(1,3),rep(2,3),rep(3,3))
out1=rnorm(length(class))
out2=rnorm(length(class))
out3=rnorm(length(class))
data=data.frame(class,out1,out2,out3)
dat.split=split(data,data$class)
for(i in 1:3){
sub[i]=dat.split[i]
}
However, the for loop doesn't work. I want to assign each split to a
different data object. Better yet, ho...
2008 May 07
2
Estimating QAIC using glm with the quasibinomial family
Hello R-list. I am a "long time listener - first time caller" who has
been using R in research and graduate teaching for over 5 years. I
hope that my question is simple but not too foolish. I've looked
through the FAQ and searched the R site mail list with some close hits
but no direct answers, so...
I would like to estimate QAIC (and QAICc) for a glm fit using the
2008 May 28
0
ia64/pv_ops: preparation: move some functions in ivt.S to avoid lack of space.
...--------------------------------------------------------------------------
- // call do_page_fault (predicates are in r31, psr.dt may be off, r16 is faulting address)
-ENTRY(page_fault)
- SSM_PSR_DT_AND_SRLZ_I
- ;;
- SAVE_MIN_WITH_COVER
- alloc r15=ar.pfs,0,0,3,0
- MOV_FROM_IFA(out0)
- MOV_FROM_ISR(out1)
- SSM_PSR_IC_AND_DEFAULT_BITS_AND_SRLZ_I(r14, r3)
- adds r3=8,r2 // set up second base pointer
- SSM_PSR_I(p15, p15, r14) // restore psr.i
- movl r14=ia64_leave_kernel
- ;;
- SAVE_REST
- mov rp=r14
- ;;
- adds out2=16,r12 // out2 = pointer to pt_regs
- br.call.sptk.many b6=ia64_do_page_fault...
2008 May 28
0
ia64/pv_ops: preparation: move some functions in ivt.S to avoid lack of space.
...--------------------------------------------------------------------------
- // call do_page_fault (predicates are in r31, psr.dt may be off, r16 is faulting address)
-ENTRY(page_fault)
- SSM_PSR_DT_AND_SRLZ_I
- ;;
- SAVE_MIN_WITH_COVER
- alloc r15=ar.pfs,0,0,3,0
- MOV_FROM_IFA(out0)
- MOV_FROM_ISR(out1)
- SSM_PSR_IC_AND_DEFAULT_BITS_AND_SRLZ_I(r14, r3)
- adds r3=8,r2 // set up second base pointer
- SSM_PSR_I(p15, p15, r14) // restore psr.i
- movl r14=ia64_leave_kernel
- ;;
- SAVE_REST
- mov rp=r14
- ;;
- adds out2=16,r12 // out2 = pointer to pt_regs
- br.call.sptk.many b6=ia64_do_page_fault...
2011 Feb 07
7
feature request
...may provide a way to write something like :
(echo 3; read > out3) |&
exec 3<&p 4>&p
echo 5 >| out5
exec 5<> out5
echo 1 |
ssh -d 3:rd -d 4:wr -d 5:rw '
read <&3; echo $REPLY >&4
read; echo $REPLY
read <&5; echo $REPLY >&5
' > out1
the expected result is 1 in out1, 3 in out3 and 5\n5 in out5.
PS : hope the sample is right :-)
Regards,
Cyrille Lefevre
--
mailto:Cyrille.Lefevre-lists at laposte.net
2015 Dec 02
4
[PATCH 3/6] Input: Update vmmouse.c to use the common VMW_PORT macros
...t; On Tue, Dec 1, 2015 at 2:32 PM, Sinclair Yeh <syeh at vmware.com> wrote:
> > > > > Hi,
> > > > >
> > >
> > > <snip>
> > >
> > > > >> > */
> > > > >> > -#define VMMOUSE_CMD(cmd, in1, out1, out2, out3, out4) \
> > > > >> > -({ \
> > > > >> > - unsigned long __dummy1, __dummy2; \
> > > > >> > - __asm__ __volatile__ ("inl %%dx" : \...
2015 Dec 02
4
[PATCH 3/6] Input: Update vmmouse.c to use the common VMW_PORT macros
...t; On Tue, Dec 1, 2015 at 2:32 PM, Sinclair Yeh <syeh at vmware.com> wrote:
> > > > > Hi,
> > > > >
> > >
> > > <snip>
> > >
> > > > >> > */
> > > > >> > -#define VMMOUSE_CMD(cmd, in1, out1, out2, out3, out4) \
> > > > >> > -({ \
> > > > >> > - unsigned long __dummy1, __dummy2; \
> > > > >> > - __asm__ __volatile__ ("inl %%dx" : \...