variable_info#
- Survey.variable_info(column_selection: str | int | list | ndarray | Series | range | Callable[[SurveyVariable], bool] | None = None, compute_value_counts: bool = True) DataFrame #
A pandas dataframe containing information about the variables (or questions).
Parameters#
- column_selectionstr, int, list, np.ndarray, pd.Series, range, QuestionSelector or None
If None, all columns are taken into account. Otherwise, a subset will be considered. The parameter is interpreted as described in
Survey.interpret_column_selection()
.- compute_value_countsbool
If True, the resulting dataframe contains information about the number of valid answers for each question and the number of unique answers for each question.
Returns#
pandas.DataFrame
Information about the selected variables.