Seite 1 von 1

Interaktionsplot

Verfasst: Do Jun 15, 2023 3:04 pm
von ninabionda
Hi zusammen,

Ich habe für meine Masterarbeit eine moderierte Regression mit R Studio durchgeführt:

Code: Alles auswählen

mod.reg <- lm(postppvt ~ preppvt * DH,
                data = Mod_PPVT)
Das hat auch geklappt.
Ich würde die Interaktion jetzt gerne graphisch abbilden und nutze dafür aus dem "interactions"-Paket:

Code: Alles auswählen

interact_plot(model=mod.reg.ppvt, pred = postppvt, modx = DH)
Ich bekomme dann folgende Error Message / Warning:

Code: Alles auswählen

geom_path()`: Each group consists of only one observation.
ℹ Do you need to adjust the group aesthetic?
Warning message:
postppvt and DH are not included in an interaction with one another in the
model.
Kann mir jemand sagen, woran das liegt? Ich komme einfach nicht drauf...

Liebe Grüße,
Nina

Re: Interaktionsplot

Verfasst: Sa Jun 17, 2023 4:26 pm
von ruedi_br
Hi,

woher kommt in dem plot-Aufruf
mod.reg.ppvt
?? Das Modell heißt im lm noch
mod.reg
VG Ruedi

Re: Interaktionsplot

Verfasst: Sa Jun 17, 2023 4:40 pm
von ninabionda
Hallo,

das war tatsächlich nur ein Schreibfehler hier im Forum... sorry für die Verwirrung!

Also das Problem besteht trotzdem, auch wenn das richtige Modell im Plot-Aufruf steht...

LG Nina