Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
Download
2701 views
1
##' \code{loadings(object)} and then design your own plotting method.
2
##' @title Side by side scores and loadings plot
3
##' @usage slplot(object, pcs=c(1,2), scoresLoadings=c(TRUE, TRUE),
4
##' sl="def", ll="def", hotelling=0.95, rug=TRUE, sub=NULL,...)
5
##' @param object
6
##' @param pcs
7
##' @param tjo
8
##' @return None, used for side effect.
9
##' @export
10
##' @author Henning Redestig
11
setMethod("slplot", "pcaRes",
12
function(object, pcs=c(1,2), tjo) {
13
#(ess-roxy-get-function-args)
14
opar <- par(no.readonly=TRUE)
15
cl <- match.call()
16
})
17
18
##' .. content for \description{} (no empty lines) ..
19
##'
20
##' .. content for \details{} ..
21
##' @title
22
##' @param a
23
##' @param b
24
##' @param d
25
##' @param asd
26
##' @return
27
##' @author Henning Redestig
28
trickyInArgsComments <- function(a,#comment
29
b,#hejhopp trams
30
d,asd) {
31
print("hello")
32
}
33
34
##' .. content for \description{} (no empty lines) ..
35
##'
36
##' .. content for \details{} ..
37
##' @title
38
##' @param a
39
##' @param b
40
##' @param cc
41
##' @return
42
##' @author Henning Redestig
43
withdef <- function(a, b=c("asd","ffd", "asd", "ffd",
44
"asd",
45
"ffd","asd",
46
"ffd"), cc) {
47
print("hello")
48
49
}
50
51
setClass(Class="inference", representation=representation(model="character"
52
, sample.size="numeric"
53
, robust.se="logical"
54
, two.sided="logical"
55
, ci.level="numeric"), contains=c("matrix"))
56
57
##' .. content for \description{} (no empty lines)
58
##'
59
##' .. content for \details{} ..
60
##' @title asd
61
##' @param a
62
##' @param asdsd
63
##' @param sd
64
##' @param ...
65
##' @return s
66
##' @author Henning Redestig
67
tempFixNasFunction <- function(a,asdsd, sd, ...) {
68
asds
69
}
70
71
setGeneric("updateMu", function(respM, gamma, ...)
72
standardGeneric("updateMu"))
73
74
75
## (make-local-variable 'adaptive-fill-regexp)
76
## (setq adaptive-fill-regexp (concat ess-roxy-str adaptive-fill-regexp))
77
## (make-local-variable 'adaptive-fill-first-line-regexp)
78
## (setq adaptive-fill-first-line-regexp (concat ess-roxy-str adaptive-fill-first-line-regexp))
79
## (make-local-variable 'paragraph-start)
80
## (setq paragraph-start (concat "\\(" ess-roxy-str "\\)*" paragraph-start))
81
## (make-local-variable 'paragraph-separate)
82
## (setq paragraph-separate (concat "\\(" ess-roxy-str "\\)*" paragraph-separate))
83
## (auto-fill-mode)
84
asd
85
86
##' aqdasd lksa odnsl dlsakdn lsakdn sladn asijdi j 1. asdsd alksnd
87
##' lasdn ldnad
88
##'
89
##'
90
##' alkdnal dl lakd lasdnladna ld aldan lda dlakd nladn a amd lakdn
91
##' ajdn asjdns
92
##'
93
##' lajnsd jasdn aksjdnaksjnd asjdnaksdnajsdnajsd aksdn askdjn
94
##' akjdn aksdnkasjdnka
95
##'
96
##' 1. aldn adlnsald ladn saldnlaksd naskl
97
##' 2. ad asdjnksadn adjn skajan kda dksadkas dkjan dkasndkadn
98
##' ajsd nkj dakjd sd
99
##' @title hej
100
##' @param fitta asdadsd
101
##' 1.
102
##' 2. asd
103
##' @param diagonals pung asa as a sad s dsa da das d asd asd
104
##' add
105
##' @param tjo asd
106
##' @param asdasd
107
##' @return me
108
##' @author Henning Redestig
109
tempFixNas <- function(fitta, diagonals, tjo, asdasd) {
110
111
for(i in index) {
112
data <- otherdata[i]
113
}
114
115
}
116
117
118
##' Simply replace completely ajksbdkjsa djskbdkajbd
119
##'
120
##' ksdb skdb skasdaj ahd (ess-roxy-beg-of-field) (newline-and-indent)
121
##' aksndlsakndlksdn jkahd ksn dkjands
122
##' @title Temporary fix for missing values
123
##' @param diagonals The diagonal to be replaced, i.e. the first,
124
##' second and so on when looking at the fat version of the matrix
125
##' @param tjo asdsdsdw
126
##' @return The original matrix with completely missing rows/cols
127
##' filled with zeroes. oasndsnd aksdnkasdnskans dkas ndkjasndksdn
128
##' skandkand ksjandknsd
129
##' @export
130
##' @examples
131
##' tempFixNas(iris)
132
##' pi <- 1
133
##' plot(x)
134
##' @author Henning Redestig
135
tempFixNas <- function(diagonals, tjo) {
136
(ess-roxy-delete-args)
137
wilcox.test
138
(ess-roxy-goto-end-of-entry)
139
badRows <- apply(mat, 1, function(x) all(is.na(x)))
140
badCols <- apply(mat, 2, function(x) all(is.na(x)))
141
mat[ badRows,] <- 0 (ess-roxy-get-args-list-from-def)
142
mat[,badCols ] <- 0 (ess-roxy-get-args-list-from-entry)
143
mat
144
}
145
146
##' <description>
147
##'
148
##' <details>
149
##' @title asdsd
150
##' @param asd asd
151
##' @param test1 asd
152
##' @param asdsd
153
##' @param tjo asdasd
154
##' @return aa
155
##' @author Henning Redestig
156
tempFixNas <- function(asd,test1,asdsd,tjo=c("asd", "asdasd")) {
157
## (ess-roxy-goto-end-of-entry)
158
## (setq fun (ess-roxy-get-args-list-from-def))
159
## (setq ent (ess-roxy-get-args-list-from-entry))
160
## (ess-roxy-merge-args fun ent)
161
## (ess-roxy-mrg-args fun ent)
162
## (ess-roxy-get-args-list-from-entry)
163
## (ess-roxy-get-function-args)
164
## (ess-roxy-goto-end-of-entry)
165
166
## (setq here (ess-roxy-delete-args))
167
## (ess-roxy-insert-args (ess-roxy-get-args-list-from-def) here)
168
badRows <- apply(mat, 1, function(x) all(is.na(x)))
169
badCols <- apply(mat, 2, function(x) all(is.na(x)))
170
mat[ badRows,] <- 0
171
mat[,badCols ] <- 0
172
mat
173
}
174
175
##' <description>
176
##'
177
##' <details>
178
##' @title my title
179
##' @param test1
180
##' @param tjo
181
##' @param pung
182
##' @param str
183
##' @return value
184
##' @author Henning Redestig
185
tempFixNasBad <- function(test1,tjo=c("asd", "asdasd"), pung, str) {
186
asdsd# (car (cdr (ess-end-of-function nil t)))
187
}
188
189
##' Provides Bayesian PCA, Probabilistic PCA, Nipals PCA, Inverse
190
##' Non-Linear PCA and the conventional SVD PCA. A cluster based
191
##' method for missing value estimation is included for comparison.
192
##' BPCA, PPCA and NipalsPCA may be used to perform PCA on incomplete
193
##' data as well as for accurate missing value estimation. A set of
194
##' methods for printing and plotting the results is also provided.
195
##' All PCA methods make use of the same data structure (pcaRes) to
196
##' provide a unique interface to the PCA results. Developed at the
197
##' Max-Planck Institute for Molecular Plant Physiology, Golm,
198
##' Germany, RIKEN Plant Science Center Yokohama, Japan, and CAS-MPG
199
##' Partner Institute for Computational Biology (PICB) Shanghai,
200
##' P.R. China
201
##'
202
##' @name pcaMethods
203
##' @aliases pcaMethods
204
##' @docType package
205
##' @title pcaMethods
206
##' @useDynLib pcaMethods
207
##' @author Wolfram Stacklies, Henning Redestig
208
NULL
209
210
211
asdsd
212
213