transform_from_values {rolap} | R Documentation |
Transform attribute values into measure names
Description
The values of an attribute will become measure names. There can only be one measure that will be from where the new defined measures take the values.
Usage
transform_from_values(ft, attribute)
## S3 method for class 'flat_table'
transform_from_values(ft, attribute = NULL)
Arguments
ft |
A |
attribute |
A string, attribute that stores the measures names. |
Value
A flat_table
object.
See Also
Other flat table transformation functions:
add_custom_column()
,
remove_instances_without_measures()
,
replace_empty_values()
,
replace_string()
,
replace_unknown_values()
,
select_attributes()
,
select_instances_by_comparison()
,
select_instances()
,
select_measures()
,
separate_measures()
,
transform_attribute_format()
,
transform_to_attribute()
,
transform_to_measure()
,
transform_to_values()
Examples
ft <- flat_table('iris', iris) |>
transform_to_values(attribute = 'Characteristic',
measure = 'Value',
id_reverse = 'id')
ft <- ft |>
transform_from_values(attribute = 'Characteristic')
[Package rolap version 2.5.1 Index]