add_item_properties: Add item properties to a project

View source: R/dexter.R

add_item_propertiesR Documentation

Add item properties to a project

Description

Add, change or define item properties in a dexter project

Usage

add_item_properties(db, item_properties = NULL, default_values = NULL)

Arguments

db

a connection to a dexter database, e.g. the output of start_new_project or open_project

item_properties

A data frame containing a column item_id (matching item_id's already defined in the project) and 1 or more other columns with item properties (e.g. item_type, subject)

default_values

a list where the names are item_properties and the values are defaults. The defaults will be used wherever the item property is unknown.

Details

When entering response data in the form of a rectangular person x item table, it is easy to provide person properties but practically impossible to provide item properties. This function provides a possibility to do so.

Note that is is not possible to add new items with this function, use touch_rules if you want to add new items to your project.

Value

nothing

See Also

fit_domains, profile_plot for possible uses of item_properties

Examples

## Not run: \donttest{
db = start_new_project(verbAggrRules, "verbAggression.db")
head(verbAggrProperties)
add_item_properties(db, verbAggrProperties)
get_items(db) 

close_project(db)
}
## End(Not run)


dexter documentation built on Sept. 11, 2024, 6:42 p.m.