forked from gvegayon/devtools
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
George Vega
committed
Apr 7, 2014
1 parent
bc4788a
commit 7ad7d28
Showing
1 changed file
with
33 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
program define devtools_demo | ||
|
||
syntax anything(name=which) | ||
|
||
noisily { | ||
di "" | ||
di "{txt}------------" | ||
di " begin demo" | ||
di "------------" | ||
capture noi demo_`which' | ||
di "{txt}------------" | ||
di " end demo" | ||
di "------------" | ||
di "" | ||
} | ||
|
||
end | ||
|
||
program define demo_dt_random_name | ||
noisily { | ||
di " > an optional argument sets length of output" | ||
di ": dt_random_name(5)" | ||
mata: dt_random_name(5) | ||
di "" | ||
di " > default length is 10" | ||
di ": dt_random_name()" | ||
mata: dt_random_name() | ||
di "" | ||
di " > optional argument should be real scalar" | ||
di `": dt_random_name("oops")"' | ||
capture noi mata: dt_random_name("oops") | ||
} | ||
end |