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

allow models of the form make_model("A; B") #164

Open
lilymedina opened this issue Mar 1, 2020 · 5 comments
Open

allow models of the form make_model("A; B") #164

lilymedina opened this issue Mar 1, 2020 · 5 comments
Assignees
Labels
bug Something isn't working low priority

Comments

@lilymedina
Copy link
Collaborator

no causal link between them

@lilymedina lilymedina self-assigned this Mar 1, 2020
@lilymedina
Copy link
Collaborator Author

lilymedina commented Mar 9, 2020

see WIP PR 165

@macartan macartan added the bug Something isn't working label Mar 12, 2020
@macartan
Copy link
Collaborator

make_model("A; B") %>% make_data
Error in [.data.frame(types, , exogenous_vars) :
undefined columns selected

@macartan
Copy link
Collaborator

macartan commented Mar 12, 2020

seems to have the wrong structure:

Statement: 
[1] "A; B"

DAG: 
  parent children
1   A; B       NA

Need something like :

dag <- data.frame(v = strsplit(statement, ";"), w = NA)

instead of dag <- data.frame(v = statement, w = NA)
in line 59

make_data and other functions probably needs tests though

@till-tietz
Copy link
Collaborator

Is there still a desire to make this a feature?

We also run into trouble creating parameters_df for this type of model; see:

m <- CausalQueries::make_model("A; B")
m$parameters_df
  param_names node    gen param_set nodal_type given param_value priors
  <chr>       <chr> <int> <chr>     <chr>      <chr>       <dbl>  <dbl>
1 A; B.0      A; B      1 A; B      0          ""            0.5      1
2 A; B.1      A; B      1 A; B      1          ""            0.5      1

@macartan
Copy link
Collaborator

macartan commented Sep 1, 2023 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working low priority
Projects
None yet
Development

No branches or pull requests

4 participants