Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Export tab-delimited text by group

    Hello!

    Given the structure of my data (example provided below), how can I export multiple tab-delimited text files by grouping variable topic? Ideally, the naming should follow: dyad1-condA.txt, dyad2-condA.txt, dyad3-condA.txt, dyadN-condA.txt

    Thank you in advance for your feedback.
    Code:
    * Example generated by -dataex-. To install: ssc install dataex
    clear
    input str391 topic str20 author long score
    "x367i" "Gavmeister123"         176
    "x367i" "unconscionable"         42
    "x367i" "j00lian"               -14
    "x367i" "Cognoggin"              71
    "x367i" "dr_rainbow"            122
    "x367i" "PrmnntThrwwy"            3
    "x367i" "breezytrees"            13
    "x367i" "hsfrey"                  5
    "x367i" "WhiskeyBerries"          1
    "x367i" "Shotgun_Mosquito"       29
    "x367i" "nukefudge"              -5
    "x367i" "felix45"                30
    "x367i" "ThomasRoll"             -5
    "x367i" "BobbyDigitalDogWnder"    2
    "x367i" "Dark1000"                0
    "x367i" "buffalorocks"           29
    "x367i" "Shayde098"               1
    "x367i" "James_Johnson"          19
    "x367i" "Lz_erk"                  1
    "x367i" "sarahcasarah"            3
    "x367i" "Absurd_Cam"              9
    "x367i" "not_czarbob"             2
    "x367i" "papersquares"           13
    "x367i" "Prone_Blocked"           6
    "x367i" "jenchilada"              1
    "x367i" "Thrice_Eye"              2
    "x367i" "control_group"          -1
    "x367i" "hhmmmm"                  2
    "x367i" "Rikicarvu"               1
    "x367i" "iLoginToComment"         1
    "x367i" "histumness"              1
    "x367i" "anonanon1313"           -1
    "x367i" "Chasuk"                  2
    "x367i" "electric33l"             2
    "x367i" "LandAlligator"           2
    "nb7n2" "byrmin"                185
    "nb7n2" "diastereomer"          278
    "nb7n2" "nalc"                  581
    "nb7n2" "olsmobile"             609
    "nb7n2" "sattizahn"            1447
    "nb7n2" "UrMomsA_ThrowAwayAct" 1028
    "nb7n2" "dicksallday"           363
    "nb7n2" "KBrace2480"            133
    "nb7n2" "hammsfamms"            539
    "nb7n2" "dubyaohohdee"         1066
    "nb7n2" "AlexKnolly"           1239
    "nb7n2" "boxy_loxy"             232
    "nb7n2" "ardbeg"               1339
    "nb7n2" "umop_ep1sdn"          1053
    "nb7n2" "thedarkwolf"          1134
    "nb7n2" "DustyDGAF"            2209
    "nb7n2" "CSec064"               618
    "nb7n2" "dukeofshuggles"       1557
    "nb7n2" "Tbickle"               343
    "nb7n2" "CaptainWizard"         242
    "nb7n2" "The_Outlaw"            197
    "nb7n2" "FaultyBeard"           686
    "nb7n2" "fluxuation"            160
    "nb7n2" "tipicaldik"            526
    "nb7n2" "Sheldy13"              897
    "nb7n2" "eiceas"                173
    "nb7n2" "jerisad"                50
    "nb7n2" "pineappleday"          150
    "nb7n2" "HalexGSd"              113
    "nb7n2" "606_10614w"            965
    "nb7n2" "luckynumberorange"     116
    "nb7n2" "nekotaku"              106
    "nb7n2" "GoochToomor"          1540
    "nb7n2" "caucasian88"           115
    "nb7n2" "faschwaa"               71
    "nb7n2" "YourRaraAvis"          457
    "nb7n2" "JNDFANTASY"             39
    "nb7n2" "Lynxface"              545
    "nb7n2" "p4r4digm"              790
    "nb7n2" "Annakha"                80
    "nb7n2" "punkwalrus"           2250
    "nb7n2" "hardtoremember"         37
    "nb7n2" "rintinSn"              165
    "nb7n2" "rasberryrum"           250
    "nb7n2" "todaysaccountname"      26
    "nb7n2" "Istealhawaiinshirts"    99
    "nb7n2" "repooper"               86
    "nb7n2" "imperativity"          368
    "nb7n2" "Trael"                 154
    "nb7n2" "VWftw"                  49
    "nb7n2" "infinity242"            17
    "nb7n2" "cucumber_breath"       163
    "nb7n2" "elitegibson"            88
    "nb7n2" "kukukele"               42
    "nb7n2" "skydivingdutch"         16
    "nb7n2" "BrainTroubles"          21
    "nb7n2" "ThirstForSavings"       21
    "nb7n2" "montereyo"              23
    "nb7n2" "QuetzalcoatI"           13
    "nb7n2" "smallestmills"         272
    "nb7n2" "wren24"                 93
    "nb7n2" "Makelevi"               27
    "nb7n2" "theshizzler"           646
    "nb7n2" "BLONDE_GIRLS"          498
    "nb7n2" "Worlds_Best_Coffee"     40
    end

  • #2
    I recall my previous comment.
    Last edited by Anton Ivanov; 08 Apr 2020, 14:45.

    Comment

    Working...
    X