Closed antonycastro closed 5 years ago
Hi Antony,
This is fairly straightforward, but will need to become familiar with ggplot2. Instead of immediately print the plot with “print(plotSpatialComparison(vegC.comparison))”; first keep the plot in an R variables like "p <- plotSpatialComparison(vegC.comparison)", and then you can modify it using ggplot2. For example:
p <- p + theme(text = element_text(size = 5))
Then, simply "print(p)".
You can do similar things for the x-axis breaks and adding captions.
The reason that you have "undefined_units" is because 'cmass_katrin' is not a known DGVMTools Quantity. The easiest way to solve that is just to rename the file back to cmass.out.
Let me know how you get on with those suggestions.
Very practical! All clear now. Thanks,
Hi again MagicForrest,
I write you because I need to polish theme and labels details in the plots produced with DGVMTools. I have attached two R-scripts and the case in a zip. I have two questions:
How can I customize the output plots? The text size of the elements is something I need to modify, also the brakes on the x-axis and would be nice to have the option to add a caption.
On the “How_to_mod_2.R” file, the output of the command: “print(plotSpatialComparison(vegC.comparison))” produce a plot with the units: “undefined units”. How could I manually change that?
Looking forward to your feedback, kind regards Antony
Magic_forest.zip