Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Change line width (thickness) sjPlot sjp.int R

I would like to change the width of the lines (thicker lines) in an sjp.int plot. I tried all help arguments, but somehow could not find it.

Example code:

require(ggplot2) 
require(sjPlot) 
head(diamonds) 
test<-lm(price ~ carat*depth, data=diamonds)
sjp.int(test, type = "eff")

sample plot

like image 797
LaNeu Avatar asked Mar 25 '26 09:03

LaNeu


1 Answers

You cannot change line size for sjp.int currently, so you have to modify the returned plot object(s), which are in the return value plot.list. Then you can overwrite geom_line().

dummy <- sjp.int(test, type = "eff")
dummy$plot.list[[1]] + geom_line(size = 3)

enter image description here

I've added a geom.size argument to sjp.int, see GitHub.

like image 101
Daniel Avatar answered Mar 27 '26 22:03

Daniel



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!