9def next_markevery(size_of_data):
10 global internal_symbol_counter
13 raise Exception(
"Too few entries to pick a correct markevery value for matplotlib")
15 default_number_of_markers = 5
16 if size_of_data<default_number_of_markers+1:
19 ten_per_plot = int( size_of_data / default_number_of_markers )
20 shift = internal_symbol_counter % ten_per_plot - 1
22 return ten_per_plot+shift
26 global internal_symbol_counter
29 if internal_symbol_counter >= len(Symbols):
31 if internal_symbol_counter >= 2*len(Symbols):
33 if internal_symbol_counter >= 3*len(Symbols):
35 result = result + Symbols[internal_symbol_counter % len(Symbols) ]
36 internal_symbol_counter+=1
37 internal_symbol_counter = internal_symbol_counter % len(4*Symbols)