Displaying 20 results from an estimated 59 matches for "y7".
2008 May 14
2
mfrow
...down (resized proportionally).
As an illustration, below is the code:
pdf("testmfrow.pdf")
par(mfrow=c(4,2))
x<-seq(1:10)
y1<-rnorm(10)
y2<-rnorm(10,mean=2,sd=1)
y3<-rnorm(10,mean=3,sd=1)
y4<-rnorm(10,mean=4,sd=1)
y5<-rnorm(10,mean=5,sd=1)
y6<-rnorm(10,mean=6,sd=1)
y7<-rnorm(10,mean=7,sd=1)
y8<-rnorm(10,mean=8,sd=1)
plot(x,y1,type='o', lty=1, main="I want this title is to be scaled down
(resized)")
plot(x,y2,type='o', lty=2, main="I want this title is to be scaled down
(resized)")
plot(x,y3,type='o', lty=3, main...
[R-pkgs] New package: `lavaan' for latent variable analysis (including structural equation modeling)
2010 May 24
2
[R-pkgs] New package: `lavaan' for latent variable analysis (including structural equation modeling)
...R Code ##
>
> library(lavaan)
>
> # The industrialization and Political Democracy Example
> # Bollen (1989), page 332
>
> model <- '
> # latent variable definitions
> ind60 =~ x1 + x2 + x3
> dem60 =~ y1 + y2 + y3 + y4
> dem65 =~ y5 + y6 + y7 + y8
>
> # regressions
> dem60 ~ ind60
> dem65 ~ ind60 + dem60
>
> # residual correlations
> y1 ~~ y5
> y2 ~~ y4 + y6
> y3 ~~ y7
> y4 ~~ y8
> y6 ~~ y8
> '
>
> fit <- sem(model, data=PoliticalDemocracy)
> summary(...
2008 May 24
2
Importing data in text file into R
...am quite new to R; facing certain problems:
Say, I have a text file( named as "try"):
Year C1 C2 C3 C4 C5 C6
Y1 3.5 13.8 9.5 6.8 0.4 24.2
Y2 3.8 13.9 9.9 7.6 0.7 12.8
Y3 4.5 14.5 14.2 9.2 0.6 14.5
Y4 5.9 16.2 24.6 12.7 0.2 24.3
Y5 7.2 20.4 40.6 18.2 0.8 28.2
Y6 5.9 18.6 37.4 14.5 0.3 36.9
Y7 8.0 16.1 88.6 24.1 0.1 34.6
Y8 13.6 21.1 56.3 19.0 0.7 33.3
I wish to import the file into R and make certain
computations, like intercorrelation matrix. I tried
the following syntax:
# Inputting the data file (saved in text format)
df="trial.txt"
idt=read.table(df,header=T, sep="\...
2009 Apr 11
2
who happenly read these two paper Mohsen Pourahmadi (biometrika1999, 2000)
...11,degree=3
here is my rocode~~
y1=c(1,0.9,0.98,1.06,0.83,1.00,0.41,0.93,1.01,0.86)
y2=c(0.05,0.16,0,0.26,0.15,0.61,0.33,0.31,0.33)
y3=c(-0.23,0,0.16,-0.03,0.22,-0.03,-0.17,-0.05)
y4=c(0.04,-0.21,-0.04,-0.26,-0.03,-0.04,-0.05)
y5=c(-0.02,-0.34,0.06,-0.22,-0.11,-0.31)
y6=c(0.20,0.01,0.01,-0.26,0.01)
y7=c(-0.06,-0.14,0.39,0.23)
y8=c(0.21,0.10,0.09)
y9=c(-0.24,-0.23)
y10=c(0.13)
y=c(y1,y2,y3,y4,y5,y6,y7,y8,y9,y10) ## autoregressive paramters ,table 1
biometrika 1999,page 685
om2=matrix(0,nrow=55,ncol=3)
om1=poly(c(1:10),degree=3) ##polynomial design matirx
with level =11,cubic
om2[1:1...
2011 Jul 05
3
[LLVMdev] optimizer returning wrong variable?
...; preds = %Until1, %
Entry
store i32 0, i32* %y
br label %Repeat2
Repeat2: ; preds = %Until2, %
Repeat1
%x3 = load i32* %x
%y4 = load i32* %y
%add = add i32 %x3, %y4
%c5 = load i32* %c
%add6 = add i32 %c5, %add
store i32 %add6, i32* %c
%y7 = load i32* %y
%add8 = add i32 %y7, 1
store i32 %add8, i32* %y
br label %Until2
Until2: ; preds = %Repeat2
%y9 = load i32* %y
%b10 = load i32* %b2
%cond = icmp sge i32 %y9, %b10
br i1 %cond, label %Repeat2, label %Untilcmp2
Untilcmp2:...
2011 Jul 05
0
[LLVMdev] optimizer returning wrong variable?
...Repeat1: ; preds = %Until1, %Entry
> store i32 0, i32* %y
> br label %Repeat2
>
> Repeat2: ; preds = %Until2, %Repeat1
> %x3 = load i32* %x
> %y4 = load i32* %y
> %add = add i32 %x3, %y4
> %c5 = load i32* %c
> %add6 = add i32 %c5, %add
> store i32 %add6, i32* %c
> %y7 = load i32* %y
> %add8 = add i32 %y7, 1
> store i32 %add8, i32* %y
> br label %Until2
>
> Until2: ; preds = %Repeat2
> %y9 = load i32* %y
> %b10 = load i32* %b2
> %cond = icmp sge i32 %y9, %b10
> br i1 %cond, label %Repeat2, label %Untilcmp2
>
> Untilcmp2: ; preds =...
2011 Aug 25
4
{R} How to extract correctly from vector?
...uot; "A3" "A4" "A5" "A6" "A7" "A8" "A9" "A10"
Now assign each element as name for a data frame:
(d <-
data.frame(cbind(X1=1,Y1=1:10,X2=1,Y2=1:10,X3=1,Y3=1:10,X4=1,Y4=1:10,X5=1,Y5
=1:10,
X6=1,Y6=1:10,X7=1,Y7=1:10,X8=1,Y8=1:10,X9=1,Y9=1:10,X10=1,Y10=1:10)))
x <- paste("X",1,sep="")
y <- paste("Y",1,sep="")
for (i in 2:10) {x[i] <- paste("X",i,sep="")
y[i] <- paste("Y",i,sep="")}
for (k in 1:...
2010 May 19
0
New package: `lavaan' for latent variable analysis (including structural equation modeling)
...the full R code for fitting a SEM model:
## begin R Code ##
library(lavaan)
# The industrialization and Political Democracy Example
# Bollen (1989), page 332
model <- '
# latent variable definitions
ind60 =~ x1 + x2 + x3
dem60 =~ y1 + y2 + y3 + y4
dem65 =~ y5 + y6 + y7 + y8
# regressions
dem60 ~ ind60
dem65 ~ ind60 + dem60
# residual correlations
y1 ~~ y5
y2 ~~ y4 + y6
y3 ~~ y7
y4 ~~ y8
y6 ~~ y8
'
fit <- sem(model, data=PoliticalDemocracy)
summary(fit, fit.measures=TRUE)
## end R code ##
Please feel free to co...
2011 Apr 27
0
lavaan version 0.4-8
...the full R code for fitting a SEM model:
## begin R Code ##
library(lavaan)
# The industrialization and Political Democracy Example
# Bollen (1989), page 332
model <- '
# latent variable definitions
ind60 =~ x1 + x2 + x3
dem60 =~ y1 + y2 + y3 + y4
dem65 =~ y5 + y6 + y7 + y8
# regressions
dem60 ~ ind60
dem65 ~ ind60 + dem60
# residual correlations
y1 ~~ y5
y2 ~~ y4 + y6
y3 ~~ y7
y4 ~~ y8
y6 ~~ y8
'
fit <- sem(model, data=PoliticalDemocracy)
summary(fit, fit.measures=TRUE)
## end R code ##
Please feel fre...
2010 May 19
0
New package: `lavaan' for latent variable analysis (including structural equation modeling)
...the full R code for fitting a SEM model:
## begin R Code ##
library(lavaan)
# The industrialization and Political Democracy Example
# Bollen (1989), page 332
model <- '
# latent variable definitions
ind60 =~ x1 + x2 + x3
dem60 =~ y1 + y2 + y3 + y4
dem65 =~ y5 + y6 + y7 + y8
# regressions
dem60 ~ ind60
dem65 ~ ind60 + dem60
# residual correlations
y1 ~~ y5
y2 ~~ y4 + y6
y3 ~~ y7
y4 ~~ y8
y6 ~~ y8
'
fit <- sem(model, data=PoliticalDemocracy)
summary(fit, fit.measures=TRUE)
## end R code ##
Please feel free to co...
2011 Apr 27
0
lavaan version 0.4-8
...the full R code for fitting a SEM model:
## begin R Code ##
library(lavaan)
# The industrialization and Political Democracy Example
# Bollen (1989), page 332
model <- '
# latent variable definitions
ind60 =~ x1 + x2 + x3
dem60 =~ y1 + y2 + y3 + y4
dem65 =~ y5 + y6 + y7 + y8
# regressions
dem60 ~ ind60
dem65 ~ ind60 + dem60
# residual correlations
y1 ~~ y5
y2 ~~ y4 + y6
y3 ~~ y7
y4 ~~ y8
y6 ~~ y8
'
fit <- sem(model, data=PoliticalDemocracy)
summary(fit, fit.measures=TRUE)
## end R code ##
Please feel fre...
2018 May 24
0
Manipulation of data.frame into an array
...17 X18 X19 X110 X111 X112 X113 X114
1 2 1 2 1 2 1 2 1 2 1 2 1 2
X115 X116 X21 X22 X23 X24 X25 X26 X27 X28 X29 X210 X211 X212
1 2 0 1 0 1 1 1 0 1 0 1 0 1
X213 X214 X215 X216 Y1 Y2 Y3 Y4 Y5 Y6 Y7 Y8 Y9 Y10
1 1 0 1 1 2 3 4 5 6 7 8 1 2
Y11 Y12 Y13 Y14 Y15 Y16
3 4 5 6 7 8
So, e.g. for a 3 column matrix:
> matrix(do.call(c,imp), ncol=3)
[,1] [,2] [,3]
[1,] 1 0 1
[2,] 2 1 2
[3,] 1 0 3...
2017 Oct 11
1
[PATCH v1 01/27] x86/crypto: Adapt assembly for PIE support
...3 */ \
- vmovdqa .Lpost_tf_lo_s2, t4; \
- vmovdqa .Lpost_tf_hi_s2, t5; \
+ vmovdqa .Lpost_tf_lo_s2(%rip), t4; \
+ vmovdqa .Lpost_tf_hi_s2(%rip), t5; \
filter_8bit(x2, t2, t3, t7, t6); \
filter_8bit(x5, t2, t3, t7, t6); \
\
@@ -443,7 +443,7 @@ ENDPROC(roundsm16_x4_x5_x6_x7_x0_x1_x2_x3_y4_y5_y6_y7_y0_y1_y2_y3_ab)
transpose_4x4(c0, c1, c2, c3, a0, a1); \
transpose_4x4(d0, d1, d2, d3, a0, a1); \
\
- vmovdqu .Lshufb_16x16b, a0; \
+ vmovdqu .Lshufb_16x16b(%rip), a0; \
vmovdqu st1, a1; \
vpshufb a0, a2, a2; \
vpshufb a0, a3, a3; \
@@ -482,7 +482,7 @@ ENDPROC(roundsm16_x4_x5_x6_x7_x0_x...
2015 Nov 21
0
[Aarch64 v2 08/18] Add Neon fixed-point implementation of xcorr_kernel.
...16(a1, y1, x0, 1);
+ int32x4_t a3 = vmlal_lane_s16(a2, y5, x4, 1);
+
+ int16x4_t y2 = vext_s16(y0, y4, 2);
+ int16x4_t y6 = vext_s16(y4, y8, 2);
+ int32x4_t a4 = vmlal_lane_s16(a3, y2, x0, 2);
+ int32x4_t a5 = vmlal_lane_s16(a4, y6, x4, 2);
+
+ int16x4_t y3 = vext_s16(y0, y4, 3);
+ int16x4_t y7 = vext_s16(y4, y8, 3);
+ int32x4_t a6 = vmlal_lane_s16(a5, y3, x0, 3);
+ int32x4_t a7 = vmlal_lane_s16(a6, y7, x4, 3);
+
+ y0 = y8;
+ a = a7;
+ x += 8;
+ y += 8;
+ }
+
+ for (; j < len; j++)
+ {
+ int16x4_t x0 = vld1_dup_s16(x); //load next x
+ int32x4_t a0 = vmlal_s16(a, y0, x0);
+
+...
2018 May 24
4
Manipulation of data.frame into an array
Hello everyone,
I want to transform a data.frame into an array (lets call it mydata), where: mydata[[1]] is the first imputed dataset...and for each mydata[[d]], the first p columns are covariates X, and the last one is the outcome Y.
Lets assume a simple data.frame:
Imputed = data.frame( X1 = c(1,2,1,2,1,2,1,2, 1,2,1,2,1,2,1,2),
X2 =
2019 Apr 24
1
Bug in "stats4" package - "confint" method
...other purpose the method ?confint? will return a wrong evaluation of the confidence interval without throwing any warning.
I suggest to use the fixed values that are already contained within the mle object:
> fit0 at fullcoef[grep('y', names(fit0 at fullcoef))]
y1 y2 y3 y4 y5 y6 y7 y8 y9 y10 y11
26 17 13 12 20 5 9 8 5 4 8
Additionally, the method ?coef? returns both the coefficient and the fixed parameters - while should return only the parameters - , while the ?fullcoef? method is not implemented - while present in the documentation of 'mle-class?....
2018 May 24
2
Manipulation of data.frame into an array
...17 X18 X19 X110 X111 X112 X113 X114
1 2 1 2 1 2 1 2 1 2 1 2 1 2
X115 X116 X21 X22 X23 X24 X25 X26 X27 X28 X29 X210 X211 X212
1 2 0 1 0 1 1 1 0 1 0 1 0 1
X213 X214 X215 X216 Y1 Y2 Y3 Y4 Y5 Y6 Y7 Y8 Y9 Y10
1 1 0 1 1 2 3 4 5 6 7 8 1 2
Y11 Y12 Y13 Y14 Y15 Y16
3 4 5 6 7 8
So, e.g. for a 3 column matrix:
> matrix(do.call(c,imp), ncol=3)
[,1] [,2] [,3]
[1,] 1 0 1
[2,] 2 1 2
[3,] 1 0 3...
2016 Nov 23
2
Active sieve script symbolic link doesn't update when changed.
While setting up sieve on my email server I mistakenly setup a symlink
(~/sieve/myfilter.svbin > ~/.dovecot.sieve) but I think that that should
have been (~/sieve/myfilter.sieve > ~/.dovecot.sieve). I have fixed the
mistake but dovecot/sieve still throws an error saying that the symlink
still links to the wrong file.
I have made sure the symlink is fixed (it links to
2007 Aug 07
1
Error in as.double.default(x) : (list) object cannot be coerced to 'double'
...ices which stands for gene expression divergence and 14 matrices which stands for gene sequence divergence. I have tried joining them by using the concatanation function giving
SequenceDivergence <- c(X1,X2,X3,X4,X5,X6,X7,X8,X9,X10,X11,X12,X13,X14)
ExpressionDivergence <- c(Y1,Y2,Y3,Y4,Y5,Y6,Y7,Y8,Y9,Y10,Y11,Y12,Y13,Y14)
where X1,X2..X14 are the expression matrices containing r-values and
Y1,Y2..Y14 are the ones with patristic distances
Now, I want to plot SequenceDivergence vs. Expression Divergence
Tried doing that using plot (Sequence Divergence vs. Expression Divergence)
But the...
2011 Jun 14
2
Need script to create new waypoint
...24, 1, 00:00:00, 00:00:00, 0
(wp2) x2, y2, 2007, 7, 24, 2, 00:00:23, 00:00:23, 2
(wp3) x3, y3, 2007, 7, 24, 3, 00:00:50, 00:00:73, 3
(wp4) x4, y4, 2007, 7, 24, 4, 00:01:20, 00:02:33, 5
(wp5) x5, y5, 2007, 7, 24, 5, 00:00:03, 00:02:36, 1
(wp6) x6, y6, 2007, 7, 24, 6, 00:00:12, 00:02:48, 2
(wp7) x7, y7, 2007, 7, 24, 7, 00:05:45, 00:08:33, 2
Now I need to change this data set into one with waypoints at regular intervals: for example 2 minutes = 120 seconds >> 2 minutes after the first waypoint (x1,y1) the baboons would be somewhere between WP3 and WP4 (at WP3 sum duration is 73 seconds and...