Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8853355
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T13:37:56+00:00 2026-06-14T13:37:56+00:00

Is it possible to omit interactions in stargazer using the omit option? Normally I

  • 0

Is it possible to omit interactions in stargazer using the omit option?
Normally I would write the variable name into the omit=c('varname') but in the case of an interaction I do not know what to write. Any hints on that?
How do you solve this problem in other packages like xtable?

\documentclass{article}   
\begin{document}   
%Load dataset and run regression    

 << lm, echo=FALSE >>=   
 load('dataset.RData')  
 library(stargazer)  
 lm1 <- lm(y~ x + factor(v)*z ,data=dataset)  
 @


 << table_texstyle, echo=FALSE, comment=NA, results='asis' >>=  
 stargazer(lm1 ,omit=c('???'), omit.labels=c('Omitted interactions'),
      omit.yes.no = c("Yes", "No")))  
  @  
   \end{document}
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-14T13:37:57+00:00Added an answer on June 14, 2026 at 1:37 pm

    If you want to omit all interactions, try

    stargazer(m1, omit = ":")
    

    This works because omit argument is expecting a regular expression. This is a very powerful tool when filtering strings. See ?regexpr or browse the regex tab here on Stackoverflow.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I would like to know how it is possible to omit a specific substring
Possible Duplicate: How do I make a request using HTTP basic authentication with PHP
Possible Duplicate: why in some scripts they omit the closing php tag ?> As
I'm writing a CouchDB sample. My intention is to write a web app using
I write code in English but I'm currently doing a site which is fully
Is it possible to omit certain variables from serialization? Say I have a temporary
Possible Duplicate: Conditional Linq Queries Using Entity Framework 4.0 I have a search condition
Possible Duplicate: Removing empty rows of a data file in R How would I
Is it possible to omit the initial build info when logging the Camel output
Is it possible to omit an aggregate column in a query? As an example:

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.