필터 지우기
필터 지우기

How to reverse the order of bubble size in 'geobubble' function to represent 'bigger dots' for smaller data values and 'smaller dots' for bigger data values

조회 수: 2 (최근 30일)
Hi,
I recently started using 'geobubble' function to plot data values at specific geographic locations described by Latitude and Longitude.
Is there a way to change the order of bubble size, where bigger dots represent smaller data values and smaller dots to represent bigger data values?
Code attached below:
counties = readtable('counties.xlsx');
gb = geobubble(counties,'Latitude','Longitude','SizeVariable','Cases2010');
geolimits(gb,[41 47],[-75 -66])
Thanks.

답변 (1개)

Aymane ahajjam
Aymane ahajjam 2023년 11월 18일
The documentation has the solution:
Reorder Bubble Colors
Change the color indicating high severity to be red rather than yellow. To change the color order, you can change the ordering of either the categories or the colors listed in the BubbleColorList property. For example, initially the categories are ordered Low-Medium-High. Use the reordercats function to change the categories to High-Medium-Low. The categories change in the color legend.
neworder = {'High','Medium','Low'};
gb.SourceTable.Severity = reordercats(gb.SourceTable.Severity,neworder);

카테고리

Help CenterFile Exchange에서 Geographic Plots에 대해 자세히 알아보기

제품


릴리스

R2017b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by