Skip to content

Commit

Permalink
DOC: fix RT03,SA01,ES01 for pandas.io.stata.StataReader.variable_labels
Browse files Browse the repository at this point in the history
  • Loading branch information
sunlight798 committed Oct 9, 2024
1 parent a0f9140 commit 7ca8e17
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
1 change: 0 additions & 1 deletion ci/code_checks.sh
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,6 @@ if [[ -z "$CHECK" || "$CHECK" == "docstrings" ]]; then
-i "pandas.errors.ValueLabelTypeMismatch SA01" \
-i "pandas.infer_freq SA01" \
-i "pandas.io.json.build_table_schema PR07,RT03,SA01" \
-i "pandas.io.stata.StataReader.variable_labels RT03,SA01" \
-i "pandas.io.stata.StataWriter.write_file SA01" \
-i "pandas.json_normalize RT03,SA01" \
-i "pandas.plotting.andrews_curves RT03,SA01" \
Expand Down
10 changes: 10 additions & 0 deletions pandas/io/stata.py
Original file line number Diff line number Diff line change
Expand Up @@ -2045,9 +2045,19 @@ def variable_labels(self) -> dict[str, str]:
"""
Return a dict associating each variable name with corresponding label.
This method retrieves variable labels from a Stata file. Variable labels are
mappings between variable names and their corresponding descriptive labels
in a Stata dataset.
Returns
-------
dict
A python dictionary.
See Also
--------
read_stata : Read Stata file into DataFrame.
DataFrame.to_stata : Export DataFrame object to Stata dta format.
Examples
--------
Expand Down

0 comments on commit 7ca8e17

Please sign in to comment.