1
votes

I need help for below code conversion from R to python.

my_fun function-> var_1=my_fun(var_1[,c(-1)],order.by=as.Date(var_1[,1]))
as.Date-> var_2[index(var_2<as.Date("2022-03-31"),colnames(var_2)%in%c("X","Y")=NA
na.rm->avg=apply(ts,2,mean,na.rm=T)
What was the problem when you tried to do it? - mkrieger1
We do not take requests for code translation here, as they do not represent a specific, answerable question. It is also not possible to give "help" in an unspecified way. - Karl Knechtel