socialmixr
socialmixr copied to clipboard
Create a common contact data class across packages
I think the different packages fill different niches and it's good to keep them all alive (especially since they are already on CRAN).
However, we should make sure that they play well together and that it is easy for users to go from one to the other.
It might also be useful to provide a shared S3 class for contact matrices so we can write common methods.
See also: https://github.com/Bisaloo/contactdata/issues/2
I think the two packages fill 2 different niches and it's good to keep them both alive (especially since both of them are already on CRAN).
I'm not 100% convinced that they need to be separate but if yes then it would indeed be a great idea to streamline the interface to be similar. We might also want to consider whether they could be named better to make the distinction clearer (as socialmixr
handles "contact data" and contacdata
provides estimates of social mixing).
It might also be useful to provide a shared S3 class for contact matrices so we can write common methods.
That is a good idea I think.
Outcome from the discussion that happened on slack:
It looks we heading towards a separate package which will provide a constructor and other methods (print()
, plot()
, accessor functions, etc.) for the S3 class we defined.
The maintainers of the individual packages keep the responsibility to convert their objects to the common class.
This means we should probably sync with conmat devs to see if:
- they would be willing to eventually update their package to use the common class
- they already have opinions on how we should build the class.
Hi there :wave:
Just chiming in to notify myself of this discussion, and also tagging in the other conmat devs, @goldingn, and @aarathybabu97
As above. Commenting for notifications on progress here.