Data Cart

Your data extract

0 variables
0 samples
View Cart
OCCSTRNG
Occupation as transcribed

OCCSTRNG is a 30-character string variable.

Explore how IPUMS created this variable

Download


      class Occstrng : public Editor {

public:
  Occstrng(VarPointer varInfo) : Editor(varInfo) {}
  void edit() {

    // Some strings are shorter coming than going out. By default
    // they get right justified which can result in :
    //
    //  "          MYNAME                "
    //
    string orig = getRecodedString();

    // fill out spaces on right:
    auto final = leftJustify(orig, varInfo->getColumnWidth(), ' ');

    setData(final);
  }
};