aphalo / ggpmisc

R package ggpmisc is an extension to ggplot2 and the Grammar of Graphics
https://docs.r4photobiology.info/ggpmisc
94 stars 6 forks source link

stat_quant_line() and consistency with stat_quant_eq() #25

Open aphalo opened 2 years ago

aphalo commented 2 years ago

I based stat_quant_line() partly on ggplot2::stat_quantile() while I wrote stat_quant_eq() almost from scratch. The current code for stat_quant_line() makes it impossible to retrieve the formula and class from the fitted model. As I have made it possible to use methods that modify the formula or call user defined functiions that in turn call a model fit function returning an acceptable fited model object, this represents a problematic inconsistency.

A rewrite based in stat_quant_eq() should not be too difficult.