dic_order: Order of Variable Levels from Eurostat Dictionary.

View source: R/dic_order.R

dic_orderR Documentation

Order of Variable Levels from Eurostat Dictionary.

Description

Orders the factor levels.

Usage

dic_order(x, dic, type)

Arguments

x

a variable (code or labelled) to get order for.

dic

a name of the dictionary. Correspond a variable name in the data_frame from get_eurostat(). Can be also data_frame from get_eurostat_dic().

type

a type of the x. Could be code or label.

Details

Some variables, like classifications, have logical or conventional ordering. Eurostat data tables are nor necessary ordered in this order. The function dic_order() get the ordering from Eurostat classifications dictionaries. The function label_eurostat() can also order factor levels of labels with argument eu_order = TRUE.

Value

A numeric vector of orders.

Author(s)

Przemyslaw Biecek, Leo Lahti, Janne Huovari and Markus Kainu

See Also

Other helpers: cut_to_classes(), eurotime2date(), eurotime2num(), harmonize_country_code(), label_eurostat()


eurostat documentation built on May 29, 2024, 2:27 a.m.