Hello,
I am very new to Stata I ve just started today and I need some help.
I have a xlsx file with some useless information in some lines. This information is text, it is like a header, but it comes like twice in the file. The columns and rows don't have names. So I would like to loop over the lines, and see if one of these lines contains a string let's say "str", if so then I will drop it.
The pseudo code would be :
for (i =0;i<nb_lines;i++){
if line.contains("str"){
drop line
}
}
The data looks like this:
Thank you in advance,
Lamya
I am very new to Stata I ve just started today and I need some help.
I have a xlsx file with some useless information in some lines. This information is text, it is like a header, but it comes like twice in the file. The columns and rows don't have names. So I would like to loop over the lines, and see if one of these lines contains a string let's say "str", if so then I will drop it.
The pseudo code would be :
for (i =0;i<nb_lines;i++){
if line.contains("str"){
drop line
}
}
The data looks like this:
the header | ||
useful info .... |
useful info ..... |
useful info .... |
the header |
Lamya
Comment