Changing visreg line colour

1.7k views Asked by At

I'm using the R package visreg to visualise the results of a model. I want to change the colour of the regression line from the default blue to black. Adding col = "black" doesn't help. How do I make this change?

Thanks!

1

There are 1 answers

1
LyzandeR On BEST ANSWER

You need to pass col = black in the line.par argument:

fit <- lm(Ozone ~ Solar.R + Wind + Temp,data=airquality)
visreg(fit, line.par = list(col = 'black'))

enter image description here