I have this dataframe, which is like a matrix. I want to limit the maximum value in df to 50, how to do this? In the resulting dataframe, 120, 110, 200 will be changed to 50. I couldn't find any source online. Thanks for your help.
df= data.frame(v1=c(1.2, 0, 1, 120),v2=c(3.5, 110, 0.8, 3),v3=c(200, 4.1, 0, 3.3))