Тёмный

Working With String Variables in Stata 

The Data Hall
Подписаться 3,7 тыс.
Просмотров 1,3 тыс.
50% 1

In this video, we discuss how to extract specific text from a string variable using substr and the word function. Further, how to count the number of characters in the string variable or count the number of words in the string variables. How to remove white spaces from the string variable or convert the case to text to upper, lower, or proper case. Check the position of specific characters in the text, or split a string variable into multiple variables.
Download the exercise file:
payhip.com/b/1...
Download Data and Do file:
thedatahall.co...
Website: thedatahall.com
As an Amazon Associate, I earn from qualifying purchases.

Опубликовано:

 

21 окт 2024

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 14   
@peepepepe3616
@peepepepe3616 20 дней назад
Hello I have a question. I have one string variable which have 4 characters the first two are the houres a the two second are the minutes How can I Split that variable into to variable one for the houres and other for the minutes?
@varunmiglani110
@varunmiglani110 Год назад
very useful commands for data management
@naimatkadha817
@naimatkadha817 11 месяцев назад
Informative as usual. I have a suggestion to please upload the do file in description of the video.
@thedatahall
@thedatahall 10 месяцев назад
Thnaks for the suggestion. I have added a link to the files in the description of this video. We will do it for other videos as well.
@naimatkadha817
@naimatkadha817 10 месяцев назад
Many thaks@@thedatahall
@rassoronmore8931
@rassoronmore8931 8 месяцев назад
This is a very useful video. I want to ask how do we match multiple words? Like if I want to look for any of the multiple words in the variable data?
@thedatahall
@thedatahall 8 месяцев назад
Please look into the inlist function, i do have a video on that, if it doesn't work the n send me an email at info@thedatahall.com along with example data.
@milimomashini9432
@milimomashini9432 Год назад
very useful sir thanks for video
@thedatahall
@thedatahall Год назад
So nice of you
@varunmiglani110
@varunmiglani110 Год назад
i have data in some cell it is: "Received" in another cell: Continuing without support now i want for both these observations to get a code of 1 in newly generated variable. how to put two criteria in strmatch
@jesuscardenas2551
@jesuscardenas2551 Год назад
Is there any way to identify blank spaces in string variables? I do not need to remove it, just to identify it
@thedatahall
@thedatahall Год назад
You can use following command gen var=1 if regexm(variable_name," ")==1
@tingting1818
@tingting1818 Год назад
thank you so much
@thedatahall
@thedatahall Год назад
Welcome
Далее
Working With Dates in Stata
22:29
Просмотров 2,9 тыс.
How to Merge (combine) Data in Stata
21:52
Просмотров 4,1 тыс.
Кольцо Всевластия от Samsung
01:00
Просмотров 377 тыс.
Improving Readability Through Fewer Arguments
13:12
Просмотров 2,5 тыс.
Stata - How to use tostring / destring
5:52
Просмотров 10 тыс.
Are Windows "Generic Keys" illegal?
13:26
Просмотров 118 тыс.
How to use STATA to do various regression analysis
1:02:16
Кольцо Всевластия от Samsung
01:00
Просмотров 377 тыс.