| plot.share {SDT} | R Documentation |
Plot Method for Objects of Class share
Description
S3 method to plot objects of the class share.
Usage
## S3 method for class 'share'
plot(x, target = NULL, reference = NULL, ...)
Arguments
x |
A required object of the class |
target |
An optional character string giving the label of the target
regulation that is used. The default value |
reference |
An optional character vector giving the labels of the
reference system base regulations that are used. The default value
|
... |
Further arguments to be passed are ignored in this function. |
Details
This plot method produces stacked bar plots of the internalization,
externalization, or simplex structure shares of a target regulation with
respect to a reference system. Generic or user-specified convenient labeling
of the plot axes are provided.
The default value target = NULL corresponds to generic labeling, which
is “intermediate regulation” in the case of the attribute value
analysis = internalization, or “target regulation” in the case
of analysis = simplex. If a character string is explicitly specified
instead, this is used to label the x-axis of the bar plot. See also
‘Examples’.
The default value reference = NULL corresponds to generic labeling,
which is “internalization share (dark)” and “externalization
share (bright)” in the case of the attribute value analysis =
internalization, or “base regulation 1 share (dark)”, “base
regulation 2 share (medium)”, and “base regulation 3 share (bright)”
in the case of analysis = simplex. If a character vector is explicitly
specified instead, which must be of length 2 for analysis =
internalization or of length 3 for analysis = simplex, this is
used to label the y-axis of the bar plot. See also ‘Examples’.
Value
If the arguments x, target, and reference are of
required types, plot.share produces the plot and invisibly returns
NULL.
Author(s)
Ali Uenlue <ali.uenlue@icloud.com>
References
Uenlue, A. and Dettweiler, U. (2015) Motivation internalization and simplex structure in self-determination theory. Psychological Reports, 117(3), 675–691. URL https://doi.org/10.2466/14.PR0.117c25z1.
See Also
The two main functions of the package, which create objects of the
class share: internalization for motivation
internalization analysis; simplex for motivation simplex
structure analysis. print.share, the S3 method for printing
objects of the class share. See also SDT-package for
general information about this package.
Examples
## attach dataset to search path (to use variable names)
attach(learning_motivation)
## internalization plot
(ijr <- internalization(introjected, intrinsic, external))
## with generic labels
plot(ijr)
## with user-specified convenient labels
plot(ijr, target = "introjected regulation",
reference = c("intrinsic regulation", "external regulation"))
## simplex structure plot 1
(simstr2 <- simplex(target_regulation = external, base_regulation_1 = intrinsic,
base_regulation_2 = identified, base_regulation_3 = introjected))
## with generic labels
plot(simstr2)
## with user-specified convenient labels
plot(simstr2, target = "external regulation",
reference = c("intrinsic regulation", "identified regulation", "introjected regulation"))
## simplex structure plot 2
## different target variable and reference system, conveniently labeled
plot(simplex(identified, intrinsic, introjected, external), target = "identified regulation",
reference = c("intrinsic regulation", "introjected regulation", "external regulation"))