Hi
I have a predictive analytics application in Shiny that uses Random forest for partial plots.
But I have the following issue:
The partial plot function gives a flat line for one of the variables when using inside a for loop.
For example:
1. partialPlot(fit1, full data ,"x")--------------- works fine
but if i do the same thing inside a loop
2. for ( i in levels)
{
partialPlot(fit1, data in i ,"x")-------------- gives a flat line.
}
3. when I isloated the data per each level separately and ran
partialPlot(fit1, data in i ,"x")--------------- works fine !
Whats happening here?