Skip to content

Commit

Permalink
minor correction
Browse files Browse the repository at this point in the history
  • Loading branch information
mingzehuang committed Aug 31, 2022
1 parent 6f1bc11 commit 8081228
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 2 deletions.
2 changes: 2 additions & 0 deletions .Rbuildignore
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,5 @@
^LICENSE$
^CODE_OF_CONDUCT.md$
^CONTRIBUTING.md$
^doc$
^Meta$
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,5 @@
.Rdata
.httr-oauth
.DS_Store
/doc/
/Meta/
2 changes: 1 addition & 1 deletion supplement/unbias_check.R
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ for (tp1 in c("con", "bin", "ter", "tru")) {
R_org = latentcor(X, types = c(tp1, tp2), method = "original")$R
R_approx = latentcor(X, types = c(tp1, tp2), method = "approx")$R
R_conapprox = latentcor(X, types = c(ifelse(tp1 == "ter", "con", tp1), ifelse(tp2 == "ter", "con", tp2)), method = "original")$R
rhorep[rep] = rho; Rrep[rep, 1] = R_org[2, 1]; Rrep[rep, 2] = R_approx[2, 1]; Rrep[rep, 3] = cor(X)[2, 1]; Rrep[rep, 4] = R_conapprox[2, 1]
Rrep[rep, 1] = R_org[2, 1]; Rrep[rep, 2] = R_approx[2, 1]; Rrep[rep, 3] = cor(X)[2, 1]; Rrep[rep, 4] = R_conapprox[2, 1]
}
assign(paste("R", cp1, cp2, tp1, tp2, "org", sep = "_"), Rrep[ , 1])
assign(paste("R", cp1, cp2, tp1, tp2, "approx", sep = "_"), Rrep[ , 2])
Expand Down
2 changes: 1 addition & 1 deletion vignettes/latentcor.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -205,7 +205,7 @@ for (s in 1:10){
# Select a random subsample of size 80
subsample = sample(1:100, 80)
# Estimate latent correlation on subsample specifying the types
Rs = latentcor(simdata2$X[subsample, ], types = NULL)
Rs = latentcor(simdata2$X[subsample, ], types = get_types(simdata2$X))
}
proc.time() - start_time
```
Expand Down

0 comments on commit 8081228

Please sign in to comment.