Hi all,
I have a series of txt file stored in a folder.
I would love to do the following (ideally via loop):
1-Open each file
2-Create a variable with same name as the file title (so it will identify the file)
3-Stored all the files in dta within the folder.
Finally, I would love to append all dta file so to have a one single dataset.
Many thanks for any advice you might have!
Related Posts with Loop opening txt file and create a variable
Generate a new variable by deleting everything after certain character ("/") Code: * Example generated by -dataex-. To install: ssc install dataex clear input str28 country "U…
Merging two data sets using joinby but with capitol and lower case differencesDear Statalisters, I need some help because I am trying to merge two databases using Code: joinby…
Strategy to choose the right controls? Conceptual questionsHello, I have a problem with chosing the right controls for my model and hope someone can help me a…
Non-linear hypotheses testing with a GSEMHello, I'm having trouble with the testnl command after a GSEM model. Specifically, my problem is th…
Looking for examples of OSIRIS dictionaries and dataDear Statalisters, I am writing a custom converter of data from OSIRIS dictionaries and need exampl…
Subscribe to:
Post Comments (Atom)
0 Response to Loop opening txt file and create a variable
Post a Comment