I want to include in a return function, an additional filter:
example:
I close the function with
return(mp_fmp[delta_fr != 0])
however, I would like to add an additional filter, such as:
return(mp_fmp[delta_fr != 0 & f_vol.t1 > 0])
apparently there is sth wrong with the new (condition= & f_vol.t1 > 0) additional filter, but I can not figure it out from the syntaxis.
Could you please help me?
Many thanks and regards
Renzo
Can you please provide a REPRoducible EXample of your problem? It provides more specifics of your problem, and it helps others to understand what problem you are facing.
In case you don't know how to make a reprex, here's a great link:
Also, please include a sample dataset and the errors you're facing while trying return(mp_fmp[delta_fr != 0 & f_vol.t1 > 0]).