Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for haven_labelled in the data explorer #634

Merged
merged 2 commits into from
Nov 27, 2024

Conversation

dfalbel
Copy link
Contributor

@dfalbel dfalbel commented Nov 22, 2024

Addresses posit-dev/positron#5327 by specializing some data explorer code paths in order to support the haven labelled data type.

At some point we might also want to implement an extension mechanism here too, allowing packages to implement a method that would create a proxy object - that's then used to compute the summary stats, histograms/freq tables, etc.

@dfalbel dfalbel requested a review from lionel- November 25, 2024 16:20
@juliasilge
Copy link
Contributor

Does this also address posit-dev/positron#5010?

@dfalbel
Copy link
Contributor Author

dfalbel commented Nov 27, 2024

No, I think for the variables pane, we'll probably want to implement a custom ark_display_value method for haven_labelled.
With the variables pane, there's no way to decide wether we really want the quotes or not.

#[test]
fn test_frequency_table_haven_labelled() {
r_task(|| {
if !package_is_installed("haven") {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also need to add haven to CI:

- name: Install R Packages Required For Tests

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done in 5434f5c

@dfalbel dfalbel merged commit 316f723 into main Nov 27, 2024
6 checks passed
@dfalbel dfalbel deleted the feature/haven_labelled branch November 27, 2024 14:25
@github-actions github-actions bot locked and limited conversation to collaborators Nov 27, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants