I want to to a raster object that has x coordinates (longitude) from 0 to 360, to standard coordinates between -180 and 180 degrees.
I have a matrix where the longitude range is (0,360) and the latitude range is (-90,90) and has a resolution of 0.75 so that its dimensions are
dim(x)
[1] 480 241
Then I try
r <- rotate(x)
And I get this error
Error in rotate(x) : object "phy" is not of class "phylo"