File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
lib/gnuplotrb/external_classes Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -13,7 +13,7 @@ class DataFrame
13
13
def to_gnuplot_points
14
14
result = ''
15
15
each_row_with_index do |row , index |
16
- quoted = index . is_a? ( String ) || index . is_a? ( Symbol )
16
+ quoted = ( index . is_a? ( String ) || index . is_a? ( Symbol ) ) && index . length > 0
17
17
result += quoted ? "\" #{ index } \" " : "#{ index } "
18
18
result += row . to_a . join ( ' ' )
19
19
result += "\n "
@@ -32,7 +32,7 @@ class Vector
32
32
def to_gnuplot_points
33
33
result = ''
34
34
each_with_index do |value , index |
35
- quoted = index . is_a? ( String ) || index . is_a? ( Symbol )
35
+ quoted = ( index . is_a? ( String ) || index . is_a? ( Symbol ) ) && index . length > 0
36
36
result += quoted ? "\" #{ index } \" " : "#{ index } "
37
37
result += "#{ value } \n "
38
38
end
You can’t perform that action at this time.
0 commit comments