Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
SaQC
Manage
Activity
Members
Labels
Plan
Issues
35
Issue boards
Milestones
Wiki
Code
Merge requests
7
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
rdm-software
SaQC
Commits
472062b5
Commit
472062b5
authored
3 years ago
by
Bert Palm
🎇
Browse files
Options
Downloads
Patches
Plain Diff
removed default fixed figure-size in interactive mode, which is unfortunate on small displays
parent
d4a11d5f
No related branches found
No related tags found
1 merge request
!283
fixed some plotting issues
Pipeline
#28968
passed with stage
Stage: test
in 2 minutes and 50 seconds
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
saqc/funcs/tools.py
+17
-4
17 additions, 4 deletions
saqc/funcs/tools.py
saqc/lib/plotting.py
+1
-1
1 addition, 1 deletion
saqc/lib/plotting.py
with
18 additions
and
5 deletions
saqc/funcs/tools.py
+
17
−
4
View file @
472062b5
...
...
@@ -261,6 +261,12 @@ def plot(
"""
Stores or shows a figure object, containing data graph with flag marks for field.
There are two modes,
'
interactive
'
and
'
store
'
mode, wich is determind via the
``save_path`` keyword. In interactive mode (default) the plot is shown at runtime
and the execution stops until the plot window is closed manually by a user. In
store mode the generated plot is stored to disk and no manually interaction is
needed.
Parameters
----------
data : {pd.DataFrame, dios.DictOfSeries}
...
...
@@ -273,8 +279,10 @@ def plot(
Flags or flagger object
save_path : str, default None
Path to the location where the figure shall be stored to.
If ``None`` is passed, plots are not stored and shown interactively instead.
If ``None`` is passed, interactive mode is entered; plots are shown immediatly
and a user need to close them manually before execution continues.
If a filepath is passed instead, store-mode is entered and
the plot is stored unter the passed location.
max_gap : str, default None
If None, all the points in the data will be connected, resulting in long linear
...
...
@@ -301,8 +309,9 @@ def plot(
removed by later tests
fig_kwargs : dict, default None
Keyword arguments controlling figure generation. ``None`` defaults to
``{
"
figsize
"
: (16, 9)}``.
Keyword arguments controlling figure generation. In interactive mode,
``None`` defaults to ``{
"
figsize
"
: (16, 9)}`` to ensure a proper figure size,
in store-mode ``None`` defaults to a empty dictionary.
save_kwargs : dict, default {}
Keywords to be passed on to the ``matplotlib.pyplot.savefig`` method, handling
...
...
@@ -347,8 +356,12 @@ def plot(
if
interactive
:
mpl
.
use
(
_MPL_DEFAULT_BACKEND
)
else
:
mpl
.
use
(
"
Agg
"
)
# ensure a proper size in stored plot
if
fig_kwargs
is
None
:
fig_kwargs
=
{
"
figsize
"
:
(
16
,
9
)}
fig
=
makeFig
(
data
=
data
,
...
...
This diff is collapsed.
Click to expand it.
saqc/lib/plotting.py
+
1
−
1
View file @
472062b5
...
...
@@ -118,7 +118,7 @@ def makeFig(
if
plot_kwargs
is
None
:
plot_kwargs
=
{
"
history
"
:
False
}
if
fig_kwargs
is
None
:
fig_kwargs
=
{
"
figsize
"
:
(
16
,
9
)
}
fig_kwargs
=
{}
if
stats_dict
is
None
:
stats_dict
=
{}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment