-
Notifications
You must be signed in to change notification settings - Fork 5
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
LDATS 0.2.0 #131
LDATS 0.2.0 #131
Conversation
pulling it out of the TS controls list
LDA_TS now takes a single "data" input that can be either a document term table or a list containing at least a document term table and optionally also a covariate table. now if a covariate table isn't provided in LDA_TS, the assumption is made that the data are equispersed in time
also added in some additional tests to fill in coverage
@Renata I tagged you as a reviewer as I'd like to make sure the update to the API works smoothly for your integration with MATSS and to make sure that I've covered all the updates that need to happen with the vignettes. I'm not completely done with this PR yet, but take a look and let me know what you think. |
Codecov Report
@@ Coverage Diff @@
## master #131 +/- ##
==========================================
+ Coverage 97.18% 97.56% +0.38%
==========================================
Files 10 11 +1
Lines 1030 1191 +161
==========================================
+ Hits 1001 1162 +161
Misses 29 29
Continue to review full report at Codecov.
|
The control lists have been made easier to interact with. Primarily, the arguments that previously required `LDA_controls_list`, `TS_controls_list`, or `LDA_TS_controls_list` inputs now take general `list` inputs (so `LDA_TS` does not need to have a nested set of control functions). Each control list is passed through a function (`LDA_set_control`, `TS_control`, or `LDA_TS_control`) to set any non-input values to their defaults. This also allows the removal of those controls list class definitions. ([addresses issue 130](#130))
@diazrenata i've got all of the updates for v0.2.0 that i wanted to get to in here, so please take a look when you can and let me know what you think/if i need to change anything. |
what is AIC was being called deviance replaced AIC with logLik for TS_fit, which allows AIC to work still and give value as before
and strictly enforcing integer or date (and thus integer) timesteps
base simulation functions for data going into an LDA or a TS from parameters
combining the two simulate functions also adding an input to the sim LDA function for Theta (allowing the simple combination of the two functions but also allowing for logical input to the LDA document by topic and topic by term)
API updates
LDA_TS
function level, the separate inputs for data tables (document_term_table
anddocument_covariate_table
) have been merged into a single inputdata
, which can be just thedocument_term_table
or a list including thedocument_term_table
and optionally also adocument_covariate_table
. If covariates aren't provided, the function now constructs a covariate table assuming equi-spaced observations. If using a list, the function assumes that one and only one element of the list will have a name containing the letters "term", and at most one element containing the letters "covariate" (regular expressions are used for matching). addresses Data API design questions #119timename
has been moved from within theTS_controls_list
to a main argument in all associated functions.LDA_controls_list
,TS_controls_list
, orLDA_TS_controls_list
inputs now take generallist
inputs (soLDA_TS
does not need to have a nested set of control functions). Each control list is passed through a function (LDA_set_control
,TS_control
, orLDA_TS_control
) to set any non-input values to their defaults. This also allows the removal of those controls list class definitions. (addresses set up the controls lists to just be lists #130)Fixed and updated example code to improve user experience
control
input in theplot
call in the example in the README (addresses plot not working with simplified example #116)Updated calculation of the number of observations in LDA
?logLik.LDA_VEM
for references.Fixed bug in plotting across multiple outputs
devAskNewPage
to help flip through multiple outputs, but were only resetting it withdevAskNewPage(FALSE)
at the end of a clean execution. The code has been updated withon.exit(devAskNewPage(FALSE))
, which accounts for failed executions. (addresses Plotting full model set first triggers plotting selected model to prompt for next plot #118)Renamed functions
summarize_TS
has been renamedpackage_TS
to align with the otherpackage_
functions that package model output.Simulate functions
sim_LDA_data
simulates an LDA model's document-term-matrixsim_TS_data
simulates an TS model's document-topic distribution matrixsim_LDA_TS_data
simulates an LDA_TS model's document-term-matrixsoftmax
andlogsumexp
are added as utility functionsImproved pkgdown site