Registry / serialization / rdata
library1.1.0pypypi✓ verified 87d ago

A Python library to read R datasets (.rda, .rdata) into Python objects. Version 1.0.0, stable release, low cadence.

pip install rdata
INSTALL
IMPORT
SIG · RDATA
R
rdata
serializationpythonv1.1.0
Install
9.0s avg
Import
1540ms
Disk
181MB
Pass rate
10/ 10
Env Coverage10 / 10
glibc
3.93.13
musl
3.93.13
Install & Compatibility
Where this runs
tested against v0.11.2 · pip install
no network on importno background threads
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
musl
py 3.103.95 runs
installs and imports cleanly · install 0.0s · import 1.570s · 178.2MB
glibc
py 3.103.95 runs
installs and imports cleanly · install 9.0s · import 1.510s · 171MB
181MB installed
● package 181MB
Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

read_rda
from rdata import read_rda
from rdata.parser import read_rda
read_rda is exposed at top-level, not in parser submodule.

Open an .rda file in binary mode and parse with read_rda. Returns a dict of R objects.

from rdata import read_rda import os # Replace with your .rda file path file_path = os.environ.get('RDATA_FILE', 'data.rda') with open(file_path, 'rb') as f: data = read_rda(f) print(data)
Debug
Known issues
breakingRequires Python >=3.11; will fail on older Python versions.
fix
Upgrade Python to 3.11 or later.
affects: 1.0.0
gotcharead_rda expects a binary file-like object, not a file path. Passing a string path raises TypeError.
fix
Open the file with open(path, 'rb') before calling read_rda.
affects: all
deprecatedThe function 'read_r' from older versions (pre-0.2) is deprecated; use read_rda instead.
fix
Replace read_r with read_rda and adjust argument order.
affects: <1.0.0
Errors
Common errors & fixes
TypeError: expected str, bytes or os.PathLike object, not bytes
Passing a path string directly to read_rda instead of a file object.
fix
Use open('file.rda', 'rb') to create a file object.
rdata._parser.RDataParserError: invalid file signature
File is not a valid .rda file or is corrupted.
fix
Verify the file is an R data file; re-save from R if needed.
Upgrade
Version history
1.1.0latest on PyPI · released Jun 11, 2026
Audit
Dependencies
pandasrequiredUsed internally for data frame conversion
Agent activity
8 hits · last 30 days
node
6
Resources
rdata — pip install rdata · libregistry