I have created an efficient frontier of some assets and have successfully plotted the results using:
efficient.frontier <- portfolioFrontier()
plot(efficient.frontier,1)
Suppose, I have another portfolio with a mean return = 0.037 and risk = 0.055. I want to visualize this portfolio on the efficient_frontier plot for comparison. I am using the code:
points(y = 0.037, x = 0.055)
However, I get the error
Error in plot.xy(xy.coords(x, y), type = type, ...) : plot.new has not been called yet.
Could you please let me know what I am doing incorrectly?