I am trying to write a program, that has option flist(string), where flist can take words such ri rm etc. Now suppose the user specifies flist(ri). How can I supply this flist macro to mata function and see there whether the user has specified ri or rm. I tried the following inside the mata function, but it returned the following error.
my question is how to evaluate a string scalar through if statement.
Code:
flist="ri" if(flist="ri") "option is ri" ; ; <istmt>: 3250 type mismatch
Comment