det_what_tm: Internal function that selects the correct markovchain object...

Description Usage Arguments Value See Also Examples

View source: R/deteriorate.R

Description

New approach that should improve speed because testing equality (of elementid) is simpler than testing inclusion in a set using

Usage

1
det_what_tm(blockbuster_initial_state_row)

Arguments

blockbuster_initial_state_row

a blockbuster dataframe or tibble single row.

Value

a markovchain object containing the appropriate transition matrix for the input blockbuster tibble row. Can only accept one row at a time due to how grep works.

See Also

blockbuster_det_data

Examples

1
2
3
4
5
6
7
8
9
old_strings_method <- det_what_tm(
dplyr::mutate_(blockbuster_pds[1, ], 
concated = ~gsub(pattern = "[^[:alnum:] ]",
replacement = "",
paste(element, sub_element, const_type,
      sep = ""))))  #  old string method lookup required concated cached
      
new_lookup_is_faster <- det_what_tm(blockbuster_pds[96, ])
      

DFE-Capital/blockbuster documentation built on March 19, 2018, 4:09 a.m.