Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add xscale and yscale arguments to CharacteristicCurve.plot() #281

Merged
merged 3 commits into from
Sep 16, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,9 @@ All notable changes to this project will be documented in this file. The format

## [Unreleased]

### Added
- Add `xscale` and `yscale` arguments to `CharacteristicCurve.plot()`.

## [5.1.0] - 2022-09-09

### Changed
Expand Down
2 changes: 1 addition & 1 deletion felupe/__about__.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
__version__ = "5.1.0"
__version__ = "5.2.0"
4 changes: 3 additions & 1 deletion felupe/mechanics/_curve.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,8 @@ def plot(
yaxis=0,
xlabel="x",
ylabel="y",
xscale=1,
yscale=1,
fig=None,
ax=None,
linestyle=".-",
Expand All @@ -70,7 +72,7 @@ def plot(
if fig is None or ax is None:
fig, ax = plt.subplots()

ax.plot(x[:, xaxis], y[:, yaxis], linestyle)
ax.plot(x[:, xaxis] * xscale, y[:, yaxis] * yscale, linestyle)
ax.set_xlabel(xlabel)
ax.set_ylabel(ylabel)

Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "felupe"
version = "5.1.0"
version = "5.2.0"
description = "Finite Element Analysis"
readme = "README.md"
requires-python = ">=3.6"
Expand Down
2 changes: 1 addition & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[metadata]
name = felupe
version = 5.1.0
version = 5.2.0
author = Andreas Dutzler
author_email = [email protected]
description = Finite Element Analysis
Expand Down