Skip to content

Commit f25b4f3

Browse files
committed
minor doc fixes
1 parent 62a7122 commit f25b4f3

File tree

8 files changed

+22
-10
lines changed

8 files changed

+22
-10
lines changed

lib/gnuplotrb/external_classes/array.rb

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
# Methods to take data for GnuplotRB plots.
33
class Array
44
# taken for example from current gnuplot bindings
5+
# @return [String] array converted to Gnuplot format
56
def to_gnuplot_points
67
return '' if self.empty?
78
case self[0]

lib/gnuplotrb/external_classes/daru.rb

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,10 @@ module Daru
66
##
77
# Methods to take data for GnuplotRB plots.
88
class DataFrame
9+
##
10+
# Convert DataFrame to Gnuplot format.
11+
#
12+
# @return [String] data converted to Gnuplot format
913
def to_gnuplot_points
1014
result = ''
1115
each_row_with_index do |row, index|
@@ -21,6 +25,10 @@ def to_gnuplot_points
2125
##
2226
# Methods to take data for GnuplotRB plots.
2327
class Vector
28+
##
29+
# Convert Vector to Gnuplot format.
30+
#
31+
# @return [String] data converted to Gnuplot format
2432
def to_gnuplot_points
2533
result = ''
2634
each_with_index do |value, index|
Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
##
22
# Methods to take data for GnuplotRB plots.
33
class String
4-
def to_gnuplot_points
5-
clone
6-
end
4+
# @return [String] data converted to Gnuplot format
5+
alias_method :to_gnuplot_points, :clone
76
end

lib/gnuplotrb/fit.rb

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@ module GnuplotRB
33
# Contains methods relating to Gnuplot's fit function. Covered in
44
# {fit notebook}[http://nbviewer.ipython.org/github/dilcom/gnuplotrb/blob/master/notebooks/fitting_data.ipynb].
55
#
6-
# You can also see original gnuplot's fit in gnuplot
7-
# doc - http://www.gnuplot.info/docs_5.0/gnuplot.pdf p. 122.
6+
# You can also see original gnuplot's fit in
7+
# {gnuplot doc}[http://www.gnuplot.info/docs_5.0/gnuplot.pdf] p. 122.
88
module Fit
99
##
1010
# Fit given data with function.
@@ -19,9 +19,9 @@ module Fit
1919
# @param :term_options [Hash] terminal options that should be setted to terminal before fit.
2020
# You can see them in Plot's documentation (or even better in gnuplot doc)
2121
# Most useful here are ranges (xrange, yrange etc) and fit option which tunes fit parameters
22-
# (see gnuplot doc - http://www.gnuplot.info/docs_5.0/gnuplot.pdf p. 122)
22+
# (see {gnuplot doc}[http://www.gnuplot.info/docs_5.0/gnuplot.pdf] p. 122)
2323
# @param options [Hash] options passed to Gnuplot's fit such as *using*. They are covered in
24-
# gnuplot doc - http://www.gnuplot.info/docs_5.0/gnuplot.pdf (pp. 69-74)
24+
# {gnuplot doc}[http://www.gnuplot.info/docs_5.0/gnuplot.pdf] (pp. 69-74)
2525
#
2626
# @return [Hash] hash with four elements:
2727
# - :formula_ds - dataset with best fit curve as data

lib/gnuplotrb/staff/dataset.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ module GnuplotRB
66
#
77
# == Options
88
# Dataset options are explained in
9-
# {gnuplot docs}[http://www.gnuplot.info/docs_5.0/gnuplot.pdf](pp. 80-101).
9+
# {gnuplot docs}[http://www.gnuplot.info/docs_5.0/gnuplot.pdf] (pp. 80-101).
1010
# Several common options:
1111
# * with - set plot style for dataset ('lines', 'points', 'impulses' etc)
1212
# * using - choose which columns of input data gnuplot should use. Takes String

lib/gnuplotrb/staff/settings.rb

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@ module GnuplotRB
22
##
33
# This module takes care of path to gnuplot executable and checking its version.
44
module Settings
5+
##
6+
# GnuplotRB can work with Gnuplot 5.0+
57
MIN_GNUPLOT_VERSION = 5.0
68

79
class << self

lib/gnuplotrb/staff/terminal.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ def store_datablock(data)
8181
##
8282
# Convert given options to gnuplot format.
8383
#
84-
# For {opt1: val1, .. , optN: valN} it returns
84+
# For "{ opt1: val1, .. , optN: valN }" it returns
8585
# set opt1 val1
8686
# ..
8787
# set optN valN
@@ -103,7 +103,7 @@ def options_hash_to_string(options)
103103
##
104104
# Applie given options to current gnuplot instance.
105105
#
106-
# For {opt1: val1, .. , optN: valN} it will output to gnuplot
106+
# For "{ opt1: val1, .. , optN: valN }" it will output to gnuplot
107107
# set opt1 val1
108108
# ..
109109
# set optN valN

lib/gnuplotrb/version.rb

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,7 @@
22
# === Overview
33
# Ruby bindings for gnuplot.
44
module GnuplotRB
5+
##
6+
# Gem version
57
VERSION = '0.3.0'
68
end

0 commit comments

Comments
 (0)