<div><br>PREZADOS</div>
<div> </div>
<div>Preciso criar uma variavel Y que é a soma de outras 3 variaveis (X1+X2+X3), porém quando uma delas é algum NA não consigo fazer a soma das outras duas.</div>
<div>como resolvo isso, como nos casos 2 e 3 abaixo.</div>
<div> </div>
<div>
<table style="WIDTH:196pt;BORDER-COLLAPSE:collapse" border="0" cellspacing="0" cellpadding="0" width="263">
<colgroup>
<col style="WIDTH:44pt" width="59">
<col style="WIDTH:38pt" span="4" width="51">
<tbody>
<tr style="HEIGHT:12.75pt" height="17">
<td style="BORDER-BOTTOM:#ece9d8;BORDER-LEFT:#ece9d8;BACKGROUND-COLOR:transparent;WIDTH:44pt;HEIGHT:12.75pt;BORDER-TOP:#ece9d8;BORDER-RIGHT:#ece9d8" height="17" width="59">caso</td>
<td style="BORDER-BOTTOM:#ece9d8;BORDER-LEFT:#ece9d8;BACKGROUND-COLOR:transparent;WIDTH:38pt;BORDER-TOP:#ece9d8;BORDER-RIGHT:#ece9d8" class="xl23" width="51"><strong>X1</strong></td>
<td style="BORDER-BOTTOM:#ece9d8;BORDER-LEFT:#ece9d8;BACKGROUND-COLOR:transparent;WIDTH:38pt;BORDER-TOP:#ece9d8;BORDER-RIGHT:#ece9d8" class="xl23" width="51"><strong>X2</strong></td>
<td style="BORDER-BOTTOM:#ece9d8;BORDER-LEFT:#ece9d8;BACKGROUND-COLOR:transparent;WIDTH:38pt;BORDER-TOP:#ece9d8;BORDER-RIGHT:#ece9d8" class="xl23" width="51"><strong>X3</strong></td>
<td style="BORDER-BOTTOM:#ece9d8;BORDER-LEFT:#ece9d8;BACKGROUND-COLOR:transparent;WIDTH:38pt;BORDER-TOP:#ece9d8;BORDER-RIGHT:#ece9d8" class="xl23" width="51"><strong>Y</strong></td></tr>
<tr style="HEIGHT:12.75pt" height="17">
<td style="BORDER-BOTTOM:#ece9d8;BORDER-LEFT:#ece9d8;BACKGROUND-COLOR:transparent;HEIGHT:12.75pt;BORDER-TOP:#ece9d8;BORDER-RIGHT:#ece9d8" class="xl24" height="17">1</td>
<td style="BORDER-BOTTOM:#ece9d8;BORDER-LEFT:#ece9d8;BACKGROUND-COLOR:transparent;BORDER-TOP:#ece9d8;BORDER-RIGHT:#ece9d8" class="xl22">1</td>
<td style="BORDER-BOTTOM:#ece9d8;BORDER-LEFT:#ece9d8;BACKGROUND-COLOR:transparent;BORDER-TOP:#ece9d8;BORDER-RIGHT:#ece9d8" class="xl22">2</td>
<td style="BORDER-BOTTOM:#ece9d8;BORDER-LEFT:#ece9d8;BACKGROUND-COLOR:transparent;BORDER-TOP:#ece9d8;BORDER-RIGHT:#ece9d8" class="xl22">1</td>
<td style="BORDER-BOTTOM:#ece9d8;BORDER-LEFT:#ece9d8;BACKGROUND-COLOR:transparent;BORDER-TOP:#ece9d8;BORDER-RIGHT:#ece9d8" class="xl22">4</td></tr>
<tr style="HEIGHT:12.75pt" height="17">
<td style="BORDER-BOTTOM:#ece9d8;BORDER-LEFT:#ece9d8;BACKGROUND-COLOR:transparent;HEIGHT:12.75pt;BORDER-TOP:#ece9d8;BORDER-RIGHT:#ece9d8" class="xl24" height="17">2</td>
<td style="BORDER-BOTTOM:#ece9d8;BORDER-LEFT:#ece9d8;BACKGROUND-COLOR:transparent;BORDER-TOP:#ece9d8;BORDER-RIGHT:#ece9d8" class="xl22">4</td>
<td style="BORDER-BOTTOM:#ece9d8;BORDER-LEFT:#ece9d8;BACKGROUND-COLOR:transparent;BORDER-TOP:#ece9d8;BORDER-RIGHT:#ece9d8" class="xl22">2</td>
<td style="BORDER-BOTTOM:#ece9d8;BORDER-LEFT:#ece9d8;BACKGROUND-COLOR:transparent;BORDER-TOP:#ece9d8;BORDER-RIGHT:#ece9d8" class="xl22">NA</td>
<td style="BORDER-BOTTOM:#ece9d8;BORDER-LEFT:#ece9d8;BACKGROUND-COLOR:transparent;BORDER-TOP:#ece9d8;BORDER-RIGHT:#ece9d8" class="xl22">NA</td></tr>
<tr style="HEIGHT:12.75pt" height="17">
<td style="BORDER-BOTTOM:#ece9d8;BORDER-LEFT:#ece9d8;BACKGROUND-COLOR:transparent;HEIGHT:12.75pt;BORDER-TOP:#ece9d8;BORDER-RIGHT:#ece9d8" class="xl24" height="17">3</td>
<td style="BORDER-BOTTOM:#ece9d8;BORDER-LEFT:#ece9d8;BACKGROUND-COLOR:transparent;BORDER-TOP:#ece9d8;BORDER-RIGHT:#ece9d8" class="xl22">NA</td>
<td style="BORDER-BOTTOM:#ece9d8;BORDER-LEFT:#ece9d8;BACKGROUND-COLOR:transparent;BORDER-TOP:#ece9d8;BORDER-RIGHT:#ece9d8" class="xl22">2</td>
<td style="BORDER-BOTTOM:#ece9d8;BORDER-LEFT:#ece9d8;BACKGROUND-COLOR:transparent;BORDER-TOP:#ece9d8;BORDER-RIGHT:#ece9d8" class="xl22">1</td>
<td style="BORDER-BOTTOM:#ece9d8;BORDER-LEFT:#ece9d8;BACKGROUND-COLOR:transparent;BORDER-TOP:#ece9d8;BORDER-RIGHT:#ece9d8" class="xl22">NA</td></tr>
<tr style="HEIGHT:12.75pt" height="17">
<td style="BORDER-BOTTOM:#ece9d8;BORDER-LEFT:#ece9d8;BACKGROUND-COLOR:transparent;HEIGHT:12.75pt;BORDER-TOP:#ece9d8;BORDER-RIGHT:#ece9d8" class="xl24" height="17">4</td>
<td style="BORDER-BOTTOM:#ece9d8;BORDER-LEFT:#ece9d8;BACKGROUND-COLOR:transparent;BORDER-TOP:#ece9d8;BORDER-RIGHT:#ece9d8" class="xl22">2</td>
<td style="BORDER-BOTTOM:#ece9d8;BORDER-LEFT:#ece9d8;BACKGROUND-COLOR:transparent;BORDER-TOP:#ece9d8;BORDER-RIGHT:#ece9d8" class="xl22">0</td>
<td style="BORDER-BOTTOM:#ece9d8;BORDER-LEFT:#ece9d8;BACKGROUND-COLOR:transparent;BORDER-TOP:#ece9d8;BORDER-RIGHT:#ece9d8" class="xl22">3</td>
<td style="BORDER-BOTTOM:#ece9d8;BORDER-LEFT:#ece9d8;BACKGROUND-COLOR:transparent;BORDER-TOP:#ece9d8;BORDER-RIGHT:#ece9d8" class="xl22">5</td></tr></tbody></colgroup></table></div>