Description Usage Arguments Details Slots of the resulting object Methods for ScaledNormalData objects Author(s) References See Also Examples
ScaledNormalData
objects represent data from a scaled Normal distribution
(a Normal, or Gaussian, distribution with variance 1).
For inferences based on this data in the framework of generalized iLUCK models,
the class ScaledNormalLuckModel
can be used.
ScaledNormalData
extends the class LuckModelData
.
Objects can be created using the constructor function ScaledNormallData()
described below.
1 2 |
arg1 |
Used for treatment of unnamed arguments only, see Details. |
arg2 |
Used for treatment of unnamed arguments only, see Details. |
data |
A vector of observations x from a Normal distribution with variance 1, i.e., x ~ N(mu,1). |
mean |
The mean of n observations from a Normal distribution with variance 1.
Must be supplied together with |
n |
The sample size of observations from a Normal distribution with variance 1
and mean given in |
sim |
If |
ScaledNormalData
objects can be created using one of the following ways:
By supplying a LuckModelData
as the only (unnamed) argument.
By supplying the mean and the sample size of a sample in mean
and n
, respectively.
one of the arguments may be unnamed.
By supplying a vector of observations in data
.
By setting sim = TRUE
, and supplying a mean and a sample size
in mean
and n
, respectively, a vector of observations is simulated.
tauN
:A matrix with two named columns, with the first giving
the sample statistic tau(x) = n*mean(x), and the second giving the corresponding
sample size n
.
rawData
:The data vector, if data was provided or simulated.
From this data, τ(x) and n in tauN
are calculated.
ScaledNormalData
objectsThere are methods to access or replace the contents of the slots:
signature(object = "ScaledNormalData")
signature(object = "ScaledNormalData")
signature(object = "ScaledNormalData")
signature(object = "ScaledNormalData")
signature(object = "ScaledNormalData")
signature(object = "ScaledNormalData")
signature(object = "ScaledNormalData")
signature(object = "ScaledNormalData")
When the slot rawData
is replaced using rawData<-
,
the contents of the slot tauN
are recalculated.
Attempts to replace (parts of) tauN
if the object
contains data in slot rawData
results in an error.
There is a method to display ScaledNormalData
objects by text:
signature(object = "ScaledNormalData")
: This is invoked
when printing a ScaledNormalData
object, or a ScaledNormalLuckModel
object
containing data.
Gero Walter
Gero Walter and Thomas Augustin (2009), Imprecision and Prior-data Conflict in Generalized Bayesian Inference, Journal of Statistical Theory and Practice 3:255-271.
luck
for a general description of the package,
and ScaledNormalLuckModel
for the model using this data representation.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 | # generate a ScaledNormalData object
set.seed(8553)
x <- rnorm(10)
scndata1 <- ScaledNormalData(data = x)
# also possible:
scndata2 <- ScaledNormalData(mean = mean(x), n = length(x))
scndata3 <- ScaledNormalData(mean = 0, n = 10, sim = TRUE)
data1 <- LuckModelData(tau=20, n=10)
scndata4 <- ScaledNormalData(data1)
# access and replace slots
tauN(scndata1)
rawData(scndata1) <- rnorm(n = 20, mean=3)
scndata1
tau(scndata2)
tau(scndata2) <- 0
n(scndata2)
n(scndata2) <- 100
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.