Skip to content

Commit

Permalink
cvs module: google docs
Browse files Browse the repository at this point in the history
  • Loading branch information
sirfoga committed Oct 7, 2018
1 parent 233f88f commit 0a61a0b
Show file tree
Hide file tree
Showing 7 changed files with 246 additions and 226 deletions.
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
10.0.6 (e55d17d4dd1b878d19ead71a57f583fe20be6193 at 22:57:18 18-10-05 +0200)
10.0.9 (f5939ff83304c2a1c3b9bd7e9e7f59c4f0380ff0 at 18:39:06 18-10-07 +0200)
32 changes: 16 additions & 16 deletions hal/charts/bars.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,11 @@ def setup_chart(title, bottom=None):
Setups chart
Args:
title: Title of chart
bottom: Bottom margin (Default value = None)
title: Title of chart
bottom: Bottom margin (Default value = None)
Returns:
Chart axis
Chart axis
"""
chart = SimpleChart(title)
if bottom:
Expand All @@ -35,10 +35,10 @@ def create_bar_chart(title, x_labels, y_values, y_label):
Creates bar char
Args:
title: Title of chart
x_labels: Names for each variable
y_values: Values of x labels
y_label: Label of y axis
title: Title of chart
x_labels: Names for each variable
y_values: Values of x labels
y_label: Label of y axis
Returns: Bar chart
"""
Expand All @@ -60,11 +60,11 @@ def create_multiple_bar_chart(title, x_labels, mul_y_values, mul_y_labels,
Creates bar chart with multiple lines
Args:
title: Title of chart
x_labels: Names for each variable
mul_y_values: list of values of x labels
mul_y_labels: list of labels for each y value
normalize: True iff you want to normalize each y series
title: Title of chart
x_labels: Names for each variable
mul_y_values: list of values of x labels
mul_y_labels: list of labels for each y value
normalize: True iff you want to normalize each y series
Returns: Bar chart
"""
Expand Down Expand Up @@ -108,10 +108,10 @@ def create_sym_log_bar_chart(title, x_labels, y_values, y_label):
Creates bar chart (log version)
Args:
title: Title of chart
x_labels: Names for each variable
y_values: Values of x labels
y_label: Label of y axis
title: Title of chart
x_labels: Names for each variable
y_values: Values of x labels
y_label: Label of y axis
Returns: Sym-log bar chart
"""
Expand Down
6 changes: 3 additions & 3 deletions hal/charts/correlation.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@ def create_correlation_matrix_plot(correlation_matrix, title, feature_list):
Creates plot for correlation matrix
Args:
correlation_matrix: Correlation matrix of features
title: Title of plot
feature_list: List of names of features
correlation_matrix: Correlation matrix of features
title: Title of plot
feature_list: List of names of features
Returns: Shows the given correlation matrix as image
"""
Expand Down
6 changes: 3 additions & 3 deletions hal/charts/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@ def __init__(self, title, grid=True):
Setups bottom margin
Args:
title: Title of chart
grid: True iff you want a chart with the grid
title: Title of chart
grid: True iff you want a chart with the grid
"""
self.title = title
self.fig = plt.figure()
Expand All @@ -28,7 +28,7 @@ def setup(self, bottom):
Setups bottom margin
Args:
bottom: Bottom margin
bottom: Bottom margin
"""
plt.gcf().subplots_adjust(bottom=bottom) # add bottom

Expand Down
107 changes: 53 additions & 54 deletions hal/charts/plotter.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ def scatter(vector_x, vector_y):
Plots scatter data
Args:
vector_x: vector in x axis
vector_y: vector in y axis
vector_x: vector in x axis
vector_y: vector in y axis
Returns: 2d scatter plot
"""
Expand All @@ -40,11 +40,11 @@ def param(function_x, function_y, min_val, max_val, points):
Plots parametric data
Args:
function_x: function in x value
function_y: function in y value
min_val: minimum value
max_val: maximum value
points: number of points to display
function_x: function in x value
function_y: function in y value
min_val: minimum value
max_val: maximum value
points: number of points to display
Returns: 2d parametric graph of given function from min to max
"""
Expand All @@ -60,10 +60,10 @@ def plot(func, min_val, max_val, points):
Plots data
Args:
func: function to plot
min_val: minimum value
max_val: maximum value
points: number of points
func: function to plot
min_val: minimum value
max_val: maximum value
points: number of points
Returns: plots 2d function
"""
Expand All @@ -87,9 +87,9 @@ def scatter(vector_x, vector_y, vector_z):
Plots scatter data
Args:
vector_x: vector in x axis
vector_y: vector in y axis
vector_z: vector in z axis
vector_x: vector in x axis
vector_y: vector in y axis
vector_z: vector in z axis
Returns: plots 3d scattered points
"""
Expand All @@ -111,12 +111,12 @@ def param(function_x, function_y, function_z, min_val, max_val,
Plots parametric functions
Args:
function_x: function in x
function_y: function in y
function_z: function in z
min_val: minimum
max_val: maximum
points: number of points
function_x: function in x
function_y: function in y
function_z: function in z
min_val: minimum
max_val: maximum
points: number of points
Returns: 3d parametric graph of given function from min to max
"""
Expand Down Expand Up @@ -153,13 +153,13 @@ def plot(func, min_x, max_x, points_x, min_y, max_y, points_y):
Plots function
Args:
func: function to plot
min_x: minimum of x-values
max_x: maximum of x-values
points_x: points in x axis
min_y: minimum of y-values
max_y: maximum of y-values
points_y: points in y axis
func: function to plot
min_x: minimum of x-values
max_x: maximum of x-values
points_x: points in x axis
min_y: minimum of y-values
max_y: maximum of y-values
points_y: points in y axis
Returns: Plots 3d function
"""
Expand Down Expand Up @@ -203,10 +203,10 @@ def scatter(vector_x, vector_y, vector_z, vector_w):
Plots scatter data
Args:
vector_x: vector in x axis
vector_y: vector in y axis
vector_z: vector in z axis
vector_w: vector in w axis
vector_x: vector in x axis
vector_y: vector in y axis
vector_z: vector in z axis
vector_w: vector in w axis
Returns: Pplot 4d scattered points
"""
Expand All @@ -222,17 +222,17 @@ def plot(func, min_x, max_x, min_y, max_y, min_z, max_z,
Plots function
Args:
func: function to plot
min_x: minimum of x-values
max_x: maximum of x-values
min_y: minimum of y-values
max_y: maximum of y-values
min_z: minimum of z-values
max_z: maximum of z-values
precision: precision (Default value = 0.5)
kind: x cont -> 3d plot with y, z variables in plane
and w as "z"-axis contour: x cont -> 3d plot with y,z variables in
plane and w colored (Default value = "contour")
func: function to plot
min_x: minimum of x-values
max_x: maximum of x-values
min_y: minimum of y-values
max_y: maximum of y-values
min_z: minimum of z-values
max_z: maximum of z-values
precision: precision (Default value = 0.5)
kind: x cont -> 3d plot with y, z variables in plane
and w as "z"-axis contour: x cont -> 3d plot with y,z variables
in plane and w colored (Default value = "contour")
Returns: Plots 4d function
"""
Expand Down Expand Up @@ -260,10 +260,10 @@ def set_labels(graph, label_x, label_y, label_z):
Set chart labels
Args:
graph: plot
label_x: new label on x axis
label_y: new label on y axis
label_z: new label on z axis
graph: plot
label_x: new label on x axis
label_y: new label on y axis
label_z: new label on z axis
Returns: Set given labels to axes of graph
"""
Expand All @@ -276,10 +276,9 @@ def set_limits(graph):
Set chart limits
Args:
graph: plot
graph: plot
Returns: set given limits to axes of graph
"""
graph.set_xlim(min_x, max_x)
graph.set_ylim(min_y, max_y)
Expand All @@ -290,8 +289,8 @@ def get_precision(min_val, max_val):
Calculates precision
Args:
min_val: minimum
max_val: maximum
min_val: minimum
max_val: maximum
Returns: precision
"""
Expand All @@ -302,8 +301,8 @@ def get_precision_delta(min_val, max_val):
Calculates precision delta
Args:
min_val: minimum
max_val: maximum
min_val: minimum
max_val: maximum
Returns: precision delte
"""
Expand All @@ -327,7 +326,7 @@ def update(val):
Updates chart with value
Args:
val: value
val: value
Returns: re-plot
"""
Expand Down Expand Up @@ -365,7 +364,7 @@ def update(val):
Updates chart with value
Args:
val: value
val: value
Returns: re-plot
"""
Expand Down

0 comments on commit 0a61a0b

Please sign in to comment.