melff / memisc

Tools for Managing Survey Data, Creating Tables of Estimates and Data Summaries
https://melff.github.io/memisc
45 stars 8 forks source link

fix #47 #48

Closed jeffreyhanson closed 4 years ago

jeffreyhanson commented 4 years ago

This PR fixes #47. Please refer to this issue for more details. @davidcanarte, if you install this fork -- e.g. using the R code: devtools::install_github("jeffreyhanson/memisc") -- this should fix the issue in your analysis code.

melff commented 4 years ago

The proposed change would create a dependency of 'memisc' on 'tibble' via the 'imports' relation. This would make maintaining the packages more difficult than necessary because the dependence of 'tibble' on other 'tidyverse' package and the interdependence of those many 'tidyverse' packages.

A far less intrusive change would be making the call setOldClass("tbl_df") conditional on the class definition not yet being present, i.e. prepending it with something like if(!("tibble" %in% loadedNamespaces())).

melff commented 4 years ago

Fixed by commit d5ee76685e7f29c74c6dac332c89e201868630fa.

davidcanarte commented 4 years ago

Hello Martin

I think I am a little lost where to make the call suggested below my email for fixing the warning messages "Found more than one class "tbl_df" in cache; using the first, from namespace 'tibble' Also defined by ‘memisc’”

Where should make this call "setOldClass("tbl_df”)”? At the beginning of my script?

Thanks

David Cañarte Ph.D. Candidate Department of Sociology and Criminology University of Florida dcanarte@ufl.edumailto:dcanarte@ufl.edu

On Aug 12, 2020, at 5:56 AM, Martin Elff notifications@github.com<mailto:notifications@github.com> wrote:

[External Email]

The proposed change would create a dependency of 'memisc' on 'tibble' via the 'imports' relation. This would make maintaining the packages more difficult than necessary because the dependence of 'tibble' on other 'tidyverse' package and the interdependence of those many 'tidyverse' packages.

A far less intrusive change would be making the call setOldClass("tbl_df") conditional on the class definition not yet being present, i.e. prepending it with something like if(!("tibble" %in% loadedNamespaces())).

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHubhttps://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_melff_memisc_pull_48-23issuecomment-2D672775891&d=DwMCaQ&c=sJ6xIWYx-zLMB3EPkvcnVg&r=MvzsRAgzzSX194v0V7MkPQ&m=x5AqH7eTHUx8Fj521dmn1nZm2JyqshrX6Q9gv9gX01s&s=qwPFGqSZMSj3bscF4OSsIIkYSqGxbxgiRR8Z5cyE380&e=, or unsubscribehttps://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_notifications_unsubscribe-2Dauth_AHVG3YX4HJS5IOC6LAATOQLSAJRL7ANCNFSM4P3YIQBQ&d=DwMCaQ&c=sJ6xIWYx-zLMB3EPkvcnVg&r=MvzsRAgzzSX194v0V7MkPQ&m=x5AqH7eTHUx8Fj521dmn1nZm2JyqshrX6Q9gv9gX01s&s=6KhUJfkxq-dUyanCEE3Ap8jKIeWCyvtXaLql7JYuXyo&e=.

melff commented 4 years ago

The problem should be fixed with the latest commit. You can install it with devtools::install_github("melff/memisc",subdir="pkg"). No need for you to do anything other than that.

davidcanarte commented 4 years ago

Thank you! Do I have to make this call one time or every time I am working on a (several different) project(s)?

David Cañarte Ph.D. Candidate Department of Sociology and Criminology University of Florida dcanarte@ufl.edumailto:dcanarte@ufl.edu

On Aug 14, 2020, at 1:04 PM, Martin Elff notifications@github.com<mailto:notifications@github.com> wrote:

devtools::install_github("melff/memisc",subdir="pkg")

melff commented 4 years ago

Only one time - just like install.packages(). You will need to install the "devtools" package first, however.

davidcanarte commented 4 years ago

Trying again because I did not load devtools before making this call. Thank you very much

David Cañarte Ph.D. Candidate Department of Sociology and Criminology University of Florida dcanarte@ufl.edumailto:dcanarte@ufl.edu

On Aug 14, 2020, at 2:57 PM, Martin Elff notifications@github.com<mailto:notifications@github.com> wrote:

[External Email]

Only one time - just like install.packages(). You will need to install the "devtools" package first, however.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHubhttps://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_melff_memisc_pull_48-23issuecomment-2D674225379&d=DwMCaQ&c=sJ6xIWYx-zLMB3EPkvcnVg&r=MvzsRAgzzSX194v0V7MkPQ&m=y-tEKnhLiXjFB9b45U5xJGYCWkJoF-sComO_vV16d9E&s=eO02KTTDZ3ZVhp1fdNfQIWI_sz1TdfW3ibfSVI1ZrCw&e=, or unsubscribehttps://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_notifications_unsubscribe-2Dauth_AHVG3YQQJ455GJHRBQZW5ZDSAWCJ5ANCNFSM4P3YIQBQ&d=DwMCaQ&c=sJ6xIWYx-zLMB3EPkvcnVg&r=MvzsRAgzzSX194v0V7MkPQ&m=y-tEKnhLiXjFB9b45U5xJGYCWkJoF-sComO_vV16d9E&s=2l7Vpv4hRFSHEyZyGc8kh8vhqfacAse4KzQmMyZpBr0&e=.