I'm looking for a simpler way to get the gscatter
to choose more intelligent colors.
As you can see in the picture below, groups 3 and 4 have very similar colors, which are difficult to differentiate.
I assign gscatter (X:, 1), X (:, 4), [], [])
.
I know that I can use scatter
to get more sensible manually, making the color of colors is the same number of colors, but I have the number of groups As is the number of colors, but how do I get a good legend like GScitt produces without looping on each group?
Simple (R) way to get more sensible color with gscatter
Thanks.
< According to the div class = "post-text" itemprop = "text">
gsciter
color specification, only letters can be used to define colors:
clr <, scatter (x, y, group, CLR, / Code> is a string array that is plot
function
Is recognized by. The default is 'bgrcmyk'
for clr
. But if you type open gscatter
and see if the GSC (X, Y, G, CLR, SIM, SIZ) color, markers, and use Specifies the size for. CLR is either a string of color specifications or
three-column matrix of color specifications .
Then you can use a color matte matrix to define colors (at least in Matlab R2014b) you want
Example:
Load Distinction Group (1: 3: End) = 3; % 2 more two group groups (2: 2: end) = 4; Benoit_11 idea to make; Equip = HSV (4); % // Define your colormate here gscatter (Rating (,, 1), Ratings (:, 2), Group, Semip)
No comments:
Post a Comment