Skip to content
This repository has been archived by the owner on Dec 14, 2023. It is now read-only.

Commit

Permalink
filter out short positions immediately on portfolio import
Browse files Browse the repository at this point in the history
closes #463
  • Loading branch information
CJ Yetman authored Oct 8, 2021
1 parent 2ab82c6 commit 88abe27
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions 0_web_functions.R
Original file line number Diff line number Diff line change
Expand Up @@ -194,6 +194,9 @@ get_input_files <- function(portfolio_name_ref_all) {
stop("Multiple investors detected. Only one investor at a time can be anaylsed")
}

# remove holdings with <= 0 market value (short positions)
portfolio <- portfolio %>% filter(market_value > 0)

return(portfolio)
}

Expand Down

0 comments on commit 88abe27

Please sign in to comment.