Questions tagged [sjplot]

sjPlot is a collection of several plotting and table output functions for data visualization o R.

About

Its a collection of several plotting and table output functions for data visualization. Results of several statistical analyses (that are commonly used in social sciences) can be visualized using this package, including simple and cross tabulated frequencies, histograms, box plots, (generalized) linear models (forest plots), PCA, correlations, cluster analyses, scatter plots etc.

Links

280 questions
0
votes
0 answers

Use plot_model to produce confidence intervals plot for multiple models

I am using the function plot_model from the sjPlot package to generate a confidence interval plot for a fixed effect linear model (felm). For the individual base model, I encountered no issues, and generated the confidence interval plot effectively.…
flâneur
  • 633
  • 2
  • 8
0
votes
1 answer

argument drop.empty not working in sjt.xtab function from sjPlot package

Lets say I have a factor level that I need to delete for the analysis for whatever reasons. I make a subset, but the factor level still exists. Luckily, there is an argument in sjt.xtab that specifies: drop.empty: Logical, if TRUE and the…
0
votes
0 answers

Running into an issue while using sjplot and subset function in logistic regression model

Issue solved: I updated my R from 4.2.0 to 4.2.1 and the issue was solved autonomically. Anyone who ran into the similar problem could try this first. I am trying use the "subset" function to remove the outliers from my model based on standardized…
T Song
  • 13
  • 4
0
votes
1 answer

Editing the appearance of the confidence intervals in a marginal effects plot

I'm producing a series of marginal effects plots from a logistic regression, using plot_model. I would like to change the appearance of the confidence intervals in the plot below, but I can't figure out a way to do it. I assume this would be through…
0
votes
1 answer

Removing line for binary predictors in a marginal effects plot using plot_model

I'm trying to produce a marginal effects plot from a logistic regression I ran, using plot_model (sjPlot), from publicly available survey data. The predictor for the plot is binary (male or female) and the response variable is whether a respondent…
0
votes
0 answers

Coefficient Plot in r for mixed model

I have fitted a three level model looking at political trust using multiple waves of survey data. Individuals nested in country-waves nested in countries. Now that I have my results, I want to present them in a coefficient plot. I have fitted a…
0
votes
1 answer

How to override p-values and remove standard errors in stargazer package?

I am trying to override the p-values that are displayed by stargazer package and its significance levels. Using this simple model (taken from the "SjPlot" package, referenced below): data(efc) library(sjPlot) # fit a model fit1 <- lm(barthtot ~…
0
votes
1 answer

custom plot of lmer random intercepts and slopes

I would like to find a way to modify the solution provided by Didzis Elferts in response to this post. I have a model with a random intercept and random slope, whereas in the original question was about a model with just a random intercept. I can't…
0
votes
1 answer

sjPlot: how to specify dependent variables?

I have a short question about the sjPlot, plot_models function. I have this code: fit1 <- lm(mpg ~ wt + cyl + disp + gear, data = mtcars) fit2 <- update(fit1, . ~ . + hp) fit3 <- update(fit2, . ~ . + am) fit4 <- lm(hp ~ wt + cyl + disp + gear,…
0
votes
1 answer

Fit several predictions plots of sjPlot in one window

I've come across a problem when using sjPlot using the "pred" function. With the model I currently have, three predictors are used in the model. NQuart3.1 <- glmmTMB(Pos_count ~ Predsumscale + Buildscale + (1|Territory), …
Ruben
  • 1
0
votes
1 answer

Why does tab_df() not print the whole table?

Thanks in advance. Basically, I've produced a table and now I just want to print that onto a word document. For some reason however, when I do so it removes all the variables from the table. Could someone pls help me out? the first line of code is…
0
votes
2 answers

How to load sjPlot when receiving namespace:insight error?

When loading sjPlot, I receive the following error: Error: package or namespace load failed for ‘sjPlot’: object ‘reshape_ci’ is not exported by 'namespace:insight' I read elsewhere that the insight package might be out of date. So I've tried to…
Tea Tree
  • 882
  • 11
  • 26
0
votes
1 answer

Plot interaction in paneldata

I have run this regression without any problems and I get 4 coefficients, for each interaction between econ_sit and educ_cat. Econ_sit is a continous variable, and educ_cat is a categorical variable from 1-6. How can i plot the coefficients only for…
RH1994
  • 37
  • 3
0
votes
0 answers

Why is the sjPlot package in R not working for me?

I installed the package sjPlot and loaded it in my R session. However, when I try to use any of the functions to create a table I just get a blank screen in the Viewer. screenshot So far I've tried to uninstall and install the package again, but…
0
votes
1 answer

Plotting population-level predictions from lme model on repeated measurements data using nlme, ggeffects, and sjplot

I have a dataset in a long format of 60 repeated measurements taken within 19 patients (ID). Patients have had a differing amount of measurements (2 measurements [n=11], followed by 5 measurements [n=5], 3 [n=1], 4 [n=1], and 6 measurements [n=1],…
tcvdb1992
  • 413
  • 3
  • 12