Changing sign of columns and values
I have the following data set in data frameIDnumber? OA? EA? beta1? ? ? ? ? ? ? ? ? ? ? ? ?C? ? ? ?A? ? ? ?-0.052? ? ? ? ? ? ? ? ? ? ? ? ?G? ? ? ? A? ? ? ? 0.0983? ? ? ? ? ? ? ? ? ? ? ? ? G? ? ? ? T? ? ? ? -0.789....I want to change the sign of negative beta. If the negative value change to postive i want to switch its EA and OA.My desire result will beIDnumber? OA? EA? beta1? ? ? ? ? ? ? ? ? ? ? ? ?A? ? ? C? ? ?0.052? ? ? ? ? ? ? ? ? ? ? ? ?G? ? ? ? A? ? ? ? 0.0983? ? ? ? ? ? ? ? ? ? ? ? ? T? ? ? ? ?G? ? ? ? 0.789....Any one can help me with r codes??kind regards,Hana