Add convert() method to convert dfm objects to dlm and KFAS formats - #104
Open
SebKrantz wants to merge 1 commit into
Open
Add convert() method to convert dfm objects to dlm and KFAS formats#104SebKrantz wants to merge 1 commit into
SebKrantz wants to merge 1 commit into
Conversation
…ersion Adds a new convert() S3 generic and convert.dfm() method that converts a dfm object into equivalent state space representations for the dlm and KFAS packages. This enables prediction intervals, forecasts, and other functionality from those packages. - convert(mod, to = "dlm"): maps FF=C, GG=A, V=R, W=Q with diffuse C0 - convert(mod, to = "KFAS"): builds SSModel with SSMcustom, Z=C, T=A, R=I, Q=Q, H=R, diffuse P1inf, with standardized data embedded Fixes #103 Co-authored-by: Sebastian Krantz <SebKrantz@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #103
Adds a
convert()S3 generic andconvert.dfm()method that converts adfmobject into equivalent state space representations for thedlmandKFASpackages.Changes
R/convert.R:convert()generic +convert.dfm()withto = c("dlm", "KFAS")DESCRIPTION: addeddlmandKFAStoSuggestsNAMESPACE: addedexport(convert)andS3method(convert,dfm)Generated with Claude Code