Yes, the folder is writable. I've taken the discussion here:
https://github.com/wbuchanan/brewscheme/issues/21
https://github.com/wbuchanan/brewscheme/issues/21
// Update if already installed from GitHub repository/project page adoupdate brewscheme, update // Install over the existing programs net inst brewscheme, from("http://wbuchanan.github.io/brewscheme/") replace
// Change the end of line delimiter #d ; // Generate the theme file used to simulate ggplot2 aesthetics brewtheme ggtheme, numticks("major 5" "horizontal_major 5" "vertical_major 5" "horizontal_minor 10" "vertical_minor 10") color("plotregion gs15" "matrix_plotregion gs15" "background gs15" "textbox gs15" "legend gs15" "box gs15" "mat_label_box gs15" "text_option_fill gs15" "clegend gs15" "histback gs15" "pboxlabelfill gs15" "plabelfill gs15" "pmarkbkfill gs15" "pmarkback gs15") linew("major_grid medthick" "minor_grid thin" "legend medium" "clegend medium") clockdir("legend_position 3") yesno("draw_major_grid yes" "draw_minor_grid yes" "legend_force_draw yes" "legend_force_nodraw no" "draw_minor_vgrid yes" "draw_minor_hgrid yes" "extend_grid_low yes" "extend_grid_high yes" "extend_axes_low no" "extend_axes_high no") gridsty("minor minor") axissty("horizontal_default horizontal_withgrid" "vertical_default vertical_withgrid") linepattern("major_grid solid" "minor_grid solid") linesty("major_grid major_grid" "minor_grid minor_grid") ticksty("minor minor_notick" "minor_notick minor_notick") ticksetsty("major_vert_withgrid minor_vert_nolabel" "major_horiz_withgrid minor_horiz_nolabel" "major_horiz_nolabel major_horiz_default" "major_vert_nolabel major_vert_default") gsize("minortick_label minuscule" "minortick tiny") numsty("legend_cols 1" "legend_rows 0" "zyx2rows 0" "zyx2cols 1") verticaltext("legend top"); // Generates a theme in the style of s2color brewtheme s2theme, graphsi("x 5.5" "y 4") numsty("legend_cols 2" "legend_rows 0" "zyx2rows 0" "zyx2cols 1") gsize("label medsmall" "small_label small" "text medium" "body medsmall" "small_body small" "heading large" "axis_title medsmall" "matrix_label medlarge" "matrix_marklbl small" "key_label medsmall" "note small" "star medsmall" "text_option medsmall" "minor_tick half_tiny" "tick_label medsmall" "tick_biglabel medium" "title_gap vsmall" "key_gap vsmall" "key_linespace vsmall" "legend_key_xsize 13" "legend_key_ysize medsmall" "clegend_width huge" "pielabel_gap zero" "plabel small" "pboxlabel small" "sts_risktable_space third_tiny" "sts_risktable_tgap zero" "sts_risktable_lgap zero" "minortick half_tiny" "pie_explode medium") relsize("bar_groupgap 67pct" "dot_supgroupgap 67pct" "box_gap 33pct" "box_supgroupgap 200pct" "box_outergap 20pct" "box_fence 67pct") symbolsi("smallsymbol small" "histogram medlarge" "ci medium" "ci2 medium" "matrix medium" "refmarker medlarge" "parrowbarb zero") color("background ltbluishgray" "foreground black" "backsymbol gs8" "heading dknavy" "box bluishgray" "textbox bluishgray" "mat_label_box bluishgray" "text_option_line black" "text_option_fill bluishgray" "filled bluishgray" "bylabel_outline bluishgray" "reverse_big navy" "reverse_big_line navy" "grid ltbluishgray" "major_grid ltbluishgray" "minor_grid gs5" "matrix navy" "matrixmarkline navy" "histback gold" "legend_line black" "clegend white" "clegend_line black" "pboxlabelfill bluishgray" "plabelfill bluishgray") linepattern("foreground solid" "background solid" "grid solid" "major_grid solid" "minor_grid dot" "text_option solid") linesty("textbox foreground" "grid grid" "major_grid major_grid" "minor_grid minor_grid" "legend legend") linewidth("p medium" "foreground thin" "background thin" "grid medium" "major_grid medium" "minor_grid thin" "tick thin" "minortick thin" "ci_area medium" "ci2_area medium" "histogram medium" "dendrogram medium" "xyline medium" "refmarker medium" "matrixmark medium" "dots vvthin" "dot_area medium" "dotmark thin" "plotregion thin" "legend thin" "clegend thin" "pie medium" "sunflower medium" "text_option thin" "pbar vvvthin") textboxsty("note small_body" "leg_caption body") axissty("bar_super horizontal_nolinetick" "dot_super horizontal_nolinetick" "bar_scale_horiz horizontal_withgrid" "bar_scale_vert vertical_withgrid" "box_scale_horiz horizontal_withgrid" "box_scale_vert vertical_withgrid") clockdir("caption_position 7" "legend_position 6" "by_legend_position 6" "p 3" "legend_caption_position 7") gridringsty("caption_ring 5" "legend_caption_ring 5") anglesty("vertical_tick vertical") yesno("extend_axes_low no" "extend_axes_high no" "draw_major_vgrid yes" "use_labels_on_ticks no" "title_span no" "subtitle_span no" "caption_span no" "note_span no" "legend_span no") barlabelsty("bar none");
loc oldhelpfiles : dir `"`c(sysdir_plus)'b/"' file "bt*.sthlp" foreach v of loc oldhelpfiles { erase `"`c(sysdir_plus)'b/`v'"' copy "https://raw.githubusercontent.com/wbuchanan/brewthemehelp/master/`v'" `"`c(sysdir_plus)'b/`v'"' } erase `"`c(sysdir_plus)'b/brewtheme.sthlp"' copy "https://raw.githubusercontent.com/wbuchanan/brewscheme/master/brewtheme.sthlp" `"`c(sysdir_plus)'b/brewtheme.sthlp"'
yesno("use_labels_on_ticks yes")
discard // 1. create theme brewtheme custom, graphsi("x 6.45" "y 4") /// numsty("legend_cols 0" "legend_rows 2" "zyx2rows 0" "zyx2cols 1") /// gsize("label med" "small_label small" "text medium" "body medsmall" "small_body small" "heading large" "axis_title small" "matrix_label medlarge" "matrix_marklbl small" "note small" "star medsmall" "text_option medsmall" "minor_tick half_tiny" "tick_label small" "tick_biglabel medium" "title_gap vsmall" "key_gap vsmall" "key_linespace vsmall" "legend_key_xsize 4" "legend_key_ysize medsmall" "key_label small" "clegend_width huge" "pielabel_gap zero" "plabel small" "pboxlabel small" "sts_risktable_space third_tiny" "sts_risktable_tgap zero" "sts_risktable_lgap zero" "minortick half_tiny" "pie_explode medium") /// relsize("bar_groupgap 67pct" "dot_supgroupgap 67pct" "box_gap 33pct" "box_supgroupgap 200pct" "box_outergap 20pct" "box_fence 67pct") /// symbolsi("smallsymbol small" "histogram medlarge" "ci medium" "ci2 medium" "matrix medium" "refmarker medlarge" "parrowbarb zero") /// color("axisline black" "tick gs12" "tick_label black" "grid gs12" "major_grid gs12" "minor_grid gs12" "matrix navy" "matrixmarkline navy" "histback gold" "legend_line white" "clegend white" "clegend_line black" "pboxlabelfill bluishgray" "plabelfill bluishgray") /// linepattern("foreground solid" "background solid" "grid solid" "major_grid solid" "minor_grid dot" "text_option solid") /// linesty("textbox foreground" "grid grid" "major_grid major_grid" "minor_grid minor_grid" "legend legend") /// linewidth("p medium" "foreground thin" "background thin" "grid thin" "major_grid thin" "minor_grid thin" "tick thin" "minortick thin" "ci_area medium" "ci2_area medium" "histogram medium" "dendrogram medium" "xyline medium" "refmarker medium" "matrixmark medium" "dots vvthin" "dot_area medium" "dotmark thin" "plotregion thin" "legend thin" "clegend thin" "pie medium" "sunflower medium" "text_option thin" "pbar vvvthin") /// textboxsty("note small_body" "leg_caption body") /// axissty("horizontal_default horizontal_withgrid" "vertical_default vertical_withgrid" "bar_super horizontal_nolinetick" "dot_super horizontal_nolinetick" "bar_scale_horiz horizontal_withgrid" "bar_scale_vert vertical_withgrid" "box_scale_horiz horizontal_withgrid" "box_scale_vert vertical_withgrid") /// clockdir("caption_position 7" "legend_position 6" "by_legend_position 6" "p 3" "legend_caption_position 7") /// gridringsty("caption_ring 5" "legend_caption_ring 5") /// anglesty("vertical_tick horizontal") /// yesno("extend_axes_low yes" "extend_axes_high no" "draw_major_vgrid yes" "draw_major_hgrid yes" "use_labels_on_ticks yes" "title_span yes" "subtitle_span yes" "caption_span no" "note_span yes" "legend_span yes") /// barlabelsty("bar none") // 2. create scheme file (using theme) brewscheme, schemename(custom) /// themefile(custom) /// allstyle(ggplot2) /// allcolors(5) /// allsaturation(75) // 3. Example sysuse auto.dta, clear format price weight %12,0gc set scheme custom twoway (fpfitci price weight) (scatter price weight if rep78==1, sort) (scatter price weight if rep78==2, sort) (scatter price weight if rep78==3, sort) (scatter price weight if rep78==4, sort) (scatter price weight if rep78==5, sort), title("Example Graph") legend(order(3 "1978 Repair Record = 1" 4 "1978 Repair Record = 2" 5 "1978 Repair Record = 3" 6 "1978 Repair Record = 4" 7 "1978 Repair Record = 5" 1 "Confidence Interval"))
discard #d ; // 1. create theme brewtheme custom, graphsi("x 6.45" "y 4") numsty("legend_cols 0" "legend_rows 2" "zyx2rows 0" "zyx2cols 1") gsize("label med" "small_label small" "text medium" "body medsmall" "small_body small" "heading large" "axis_title small" "matrix_label medlarge" "matrix_marklbl small" "note small" "star medsmall" "text_option medsmall" "minor_tick half_tiny" "tick_label small" "tick_biglabel medium" "title_gap vsmall" "key_gap vsmall" "key_linespace vsmall" "legend_key_xsize 4" "legend_key_ysize medsmall" "key_label small" "clegend_width huge" "pielabel_gap zero" "plabel small" "pboxlabel small" "sts_risktable_space third_tiny" "sts_risktable_tgap zero" "sts_risktable_lgap zero" "minortick half_tiny" "pie_explode medium") relsize("bar_groupgap 67pct" "dot_supgroupgap 67pct" "box_gap 33pct" "box_supgroupgap 200pct" "box_outergap 20pct" "box_fence 67pct") symbolsi("smallsymbol small" "histogram medlarge" "ci medium" "ci2 medium" "matrix medium" "refmarker medlarge" "parrowbarb zero") color("axisline black" "tick gs12" "tick_label black" "grid gs12" "major_grid gs12" "minor_grid gs12" "matrix navy" "matrixmarkline navy" "histback gold" "legend_line white" "clegend white" "clegend_line black" "pboxlabelfill bluishgray" "plabelfill bluishgray") linepattern("foreground solid" "background solid" "grid solid" "major_grid solid" "minor_grid dot" "text_option solid") linesty("textbox foreground" "grid grid" "major_grid major_grid" "minor_grid minor_grid" "legend legend") linewidth("p medium" "foreground thin" "background thin" "grid thin" "major_grid thin" "minor_grid thin" "tick thin" "minortick thin" "ci_area medium" "ci2_area medium" "histogram medium" "dendrogram medium" "xyline medium" "refmarker medium" "matrixmark medium" "dots vvthin" "dot_area medium" "dotmark thin" "plotregion thin" "legend thin" "clegend thin" "pie medium" "sunflower medium" "text_option thin" "pbar vvvthin") textboxsty("note small_body" "leg_caption body") axissty("horizontal_default horizontal_withgrid" "vertical_default vertical_withgrid" "bar_super horizontal_nolinetick" "dot_super horizontal_nolinetick" "bar_scale_horiz horizontal_withgrid" "bar_scale_vert vertical_withgrid" "box_scale_horiz horizontal_withgrid" "box_scale_vert vertical_withgrid") clockdir("caption_position 7" "legend_position 6" "by_legend_position 6" "p 3" "legend_caption_position 7") gridringsty("caption_ring 5" "legend_caption_ring 5") anglesty("vertical_tick horizontal") yesno("extend_axes_low yes" "extend_axes_high no" "draw_major_vgrid yes" "draw_major_hgrid yes" "use_labels_on_ticks yes" "title_span yes" "subtitle_span yes" "caption_span no" "note_span yes" "legend_span yes") barlabelsty("bar none"); // 2. create scheme file (using theme) brewscheme, schemename(custom) themefile(custom) allstyle(ggplot2) allcolors(5) allsaturation(75); // 3. Example sysuse auto.dta, clear; format price weight %12,0gc; // Unless you're planning on hand coding a lot of graphs, I would personally // avoid setting the scheme globally // set scheme custom // And pass the scheme as an argument to the graph command twoway (fpfitci price weight) (scatter price weight if rep78==1, sort) (scatter price weight if rep78==2, sort) (scatter price weight if rep78==3, sort) (scatter price weight if rep78==4, sort) (scatter price weight if rep78==5, sort), title("Example Graph") legend(order(3 "1978 Repair Record = 1" 4 "1978 Repair Record = 2" 5 "1978 Repair Record = 3" 6 "1978 Repair Record = 4" 7 "1978 Repair Record = 5" 1 "Confidence Interval")) scheme(custom);
. sysuse auto, clear (1978 Automobile Data) . brewscheme, scheme(test) allstyle(dark2) allcolor(7) file http://www.colorbrewer2.org/colorbrewer_schemes.js not found server says file permanently redirected to http://colorbrewer2.org/colorbrewer_schemes.js r(601);
Comment