mirror of
https://github.com/Magnus167/msyrs.git
synced 2025-08-20 04:20:00 +00:00
refactor: simplify type annotations in reduce_dataframe function
This commit is contained in:
parent
5c3862c297
commit
5ef2c7e6c7
@ -30,12 +30,12 @@ pub fn reduce_dataframe(
|
||||
let df_size = df.shape();
|
||||
let mut new_df = df.clone();
|
||||
|
||||
let ticker_col: Column = get_ticker_column_for_quantamental_dataframe(&new_df)?;
|
||||
let ticker_col = get_ticker_column_for_quantamental_dataframe(&new_df)?;
|
||||
|
||||
// if cids is not provided, get all unique cids
|
||||
let u_cids: Vec<String> = get_unique_cids(&new_df)?;
|
||||
let u_xcats: Vec<String> = get_unique_xcats(&new_df)?;
|
||||
let u_tickers: Vec<String> = _get_unique_strs_from_str_column_object(&ticker_col)?;
|
||||
let u_cids = get_unique_cids(&new_df)?;
|
||||
let u_xcats = get_unique_xcats(&new_df)?;
|
||||
let u_tickers = _get_unique_strs_from_str_column_object(&ticker_col)?;
|
||||
|
||||
let cids_vec = cids.unwrap_or_else(|| u_cids.clone());
|
||||
let specified_cids: Vec<&str> = cids_vec.iter().map(AsRef::as_ref).collect();
|
||||
|
Loading…
x
Reference in New Issue
Block a user