Adição

Adição

Escrevi as equações e consegui alinhar a regressão, mas os números estão aparecendo abaixo da regressão. Como posso alinhá-lo à direita?

este é o código que estou usando:

\begin{equation}
\label{reg5}
\begin{align}

\begin{small}PRODUCTION_{i,t} = b_0 + b_1FORECAST_{i,t} + b_2PEER\_FORECAST_{i,t} + 

b_3FORECAST_{i,t} * CEO\_TURNOVER_{t-1}  + 

b_4PEER\_FORECAST_{i,t} * CEO\_TURNOVER_{t-1}  + b_5UNEMP_{t-1} + 

b_6HORIZON_t\end{small}                                                                          
\end{align}
\end{equation}

Alguém pode me ajudar com isso?

Responder1

Elaborando a resposta de Werner (com elogios à sua bola de cristal… :-)

\documentclass[a4paper]{article}
\usepackage[T1]{fontenc} % not actually necessary, but recommended
\usepackage[width=14cm]{geometry} % just for this example
\usepackage{amsmath}

\begin{document}

Text before.
\begin{equation}
    \begin{split}
        \text{PRODUCTION}_{i,t} &=
            b_0 + b_1 \text{FORECAST}_{i,t} + b_2 \text{PEER\_FORECAST}_{i,t} \\
            &\qquad + b_3 \text{FORECAST}_{i,t} \times \text{CEO\_TURNOVER}_{t-1} \\
            &\qquad + b_4 \text{PEER\_FORECAST}_{i,t} \times \text{CEO\_TURNOVER}_{t-1} \\
            &\qquad + b_5 \text{UNEMP}_{t-1} + b_6 \text{HORIZON}_t
    \end{split}
\end{equation}
Text after.

\end{document}

(depois de ver o resultado, decidi que prefiro \qquad) \quad. Aqui está a saída:

Saída do código


Adição

Com as sugestões de @egreg, o código fica

\documentclass[a4paper]{article}
\usepackage[T1]{fontenc} % not actually necessary, but recommended
\usepackage[width=14cm]{geometry} % just for this example
\usepackage{amsmath}

\begin{document}

Text before.
\begin{equation}
    \begin{split}
        \text{PRODUCTION}_{i,t} =
            b_0 &+ b_1\,\text{FORECAST}_{i,t} + b_2\,\text{PEER\_FORECAST}_{i,t} \\
            &+ b_3\,\text{FORECAST}_{i,t} \times \text{CEO\_TURNOVER}_{t-1} \\
            &+ b_4\,\text{PEER\_FORECAST}_{i,t} \times \text{CEO\_TURNOVER}_{t-1} \\
            &+ b_5\,\text{UNEMP}_{t-1} + b_6\,\text{HORIZON}_t
    \end{split}
\end{equation}
Text after.

\end{document}

que fornece a seguinte saída:

Saída do segundo exemplo de código

Responder2

Você provavelmente está procurando algo assim:

insira a descrição da imagem aqui

\documentclass{article}

\usepackage[margin=1in]{geometry}% Just for this example
\usepackage{amsmath}

\begin{document}

\begin{align}
  \text{PRODUCTION}_{i,t} &= b_0 + b_1 \text{FORECAST}_{i,t} + b_2 \text{PEER\_FORECAST}_{i,t} + \nonumber \\
    &\phantom{{}={}} b_3 \text{FORECAST}_{i,t} \times \text{CEO\_TURNOVER}_{t-1} + \nonumber \\
    &\phantom{{}={}} b_4 \text{PEER\_FORECAST}_{i,t} \times \text{CEO\_TURNOVER}_{t-1} + b_5 \text{UNEMP}_{t-1} + \nonumber \\
    &\phantom{{}={}} b_6 \text{HORIZON}_t
\end{align}

\end{document}

Alguns problemas com seu código:

  • Você não pode usar um aligninside equation;

  • Não deixe linhas em branco dentro align;

  • Não use escala de fonte relacionada ao texto dentro do modo matemático (como \small);

  • smalltecnicamente não é um ambiente.

A numeração pode ser suprimida para alignuso \nonumber.

informação relacionada