View source: R/generate.data2d.R
generate.data2d | R Documentation |
Generate two-dimensional data related to the f1 function
of Lu et al. (2012) (code from author). Define n =
c(60, 80)
. Then x[[i]] = (1:n[i])/n[i] -
1/2/n[i]
. These are the observed data locations. For
i
and j
spanning the full length of each
element of x
, mu2d[i, j] = sin(2 * pi *
(x[[1]][i] - .5) ^ 3) * cos(4 * pi * x[[2]][j])
. Lastly,
data2d = mu2d + rnorm(prod(n))
.
generate.data2d()
generate_data2d()
generateData2d()
GenerateData2d()
A list with components x
, mu2d
, and
data2d
. x
is a list of sequences with
length 60 and 80. mu2d
and data2d
are
matrices of size 60 by 80.
Joshua French. Based off code by Luo Xiao (see References).
Xiao, L. , Li, Y. and Ruppert, D. (2013), Fast bivariate P-splines: the sandwich smoother. J. R. Stat. Soc. B, 75: 577-599. <doi:10.1111/rssb.12007>
dat = generate.data2d()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.