1

Searched stackoverflow multiple times for a solution to this question. One of the fundamental issues I am encountering is that I am unable to predict the interaction effects of certain model averaged coefficients on the response. I am currently running an occupancy model, where I would like to visualize the effect of certain model averaged coefficients on the response (0/1)

Here's what a model averaged object from `MuMIn' looks like:

c

Call:
model.avg(object = top_clim_elev[[8]], fit = TRUE)

Component models: 
‘1/2/3/4/5/6/7/8/9/10/11/12/13’          ‘1/2/3/4/5/6/7/8/9/10/11/13’             
‘1/2/3/4/5/6/7/8/9/10/11/13/15’          ‘1/2/3/4/5/6/7/8/9/10/11/12/13/15’       
‘1/2/3/4/5/6/7/8/9/10/11/12/13/15/16’    ‘1/2/3/4/5/6/7/8/9/10/11/12/13/16’       
‘1/2/3/4/5/6/7/8/9/10/11/12/13/14’       ‘1/2/3/4/5/6/7/8/9/10/11/13/14’          
‘1/2/3/4/5/6/7/8/9/10/11/13/14/15’       ‘1/2/3/4/5/6/7/8/9/10/11/12/13/14/15’    
‘1/2/3/4/5/6/7/8/9/10/11/12/13/14/15/16’ ‘1/2/3/4/5/6/7/8/9/10/11/12/13/14/16’   

 Coefficients: 
        psi(Int)  psi(alt.y) psi(bio_17.y) psi(bio_18.y) psi(bio_4.y) psi(prec_interannual.y)
 full   -3.10525 -0.05192473    -0.2068835     -1.482401    0.6015917               0.2626282
 subset -3.10525 -0.05192473    -0.2068835     -1.482401    0.6015917               0.4324259
        psi(alt.y:bio_17.y)    p(Int) p(duration_minutes) p(effort_distance_km) p(expertise)
 full            -0.7490456 -1.245292            0.411762           -0.05852994    0.3375549
 subset          -0.7490456 -1.245292            0.411762           -0.05852994    0.3375549
        p(julian_date) p(min_obs_started) p(number_observers) p(protocol_typeTraveling)
 full      -0.04548198        -0.01558561         -0.02327381                 0.3527979
 subset    -0.04548198        -0.01558561         -0.02327381                 0.3527979
        psi(alt.y:bio_4.y) psi(alt.y:prec_interannual.y) psi(alt.y:bio_18.y)
 full           0.09419262                    0.05598506          0.01681933
 subset         0.24061807                    0.26320150          0.06110500

I considered wrote the coefficients out of the full model as a dataframe, along with the standard error and upper and lower CI.

For example:

enter image description here

I would like to use the coefficient estimates for alt.y:bio_17.y and predict it's effect on the response as a function of the moderator alt.y. I have tried multiple ways to do the same, but would like to achieve the 'predict' function in R without having the need to store a model object. Further, even if I store a model averaged object in R, as shown above - I am unable to use the same via packages like sjPlot or others in R.

Vijay Ramesh
  • 191
  • 1
  • 2
  • 20
  • 4
    Could you clarify what your data looks like? What are the variables in your model? Preferably, provide a toy data set. – broti Apr 16 '20 at 07:45

0 Answers0