Skip to content

Commit

Permalink
readme: minor updates
Browse files Browse the repository at this point in the history
  • Loading branch information
tdegeus committed Dec 30, 2022
1 parent 33cbd23 commit d23c16d
Showing 1 changed file with 15 additions and 13 deletions.
28 changes: 15 additions & 13 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -59,21 +59,23 @@ which prints the probability density of each bin (so list of values around `0.1`

The `histogram` class contains two nice features.

1. It has several bin algorithms that matplotlib does not have.
2. It can be used for plotting with an ultra-sort interface.
1. It has several bin algorithms that NumPy does not have.

```python
import enstat
import matplotlib.pyplot as plt
2. It can be used for plotting with an ultra-sort interface, for example:

data = np.random.random(1000)
hist = enstat.histogram.from_data(data, bins=10, mode="log")
```python
import enstat
import matplotlib.pyplot as plt

fig, ax = plt.subplots()
ax.plot(hist.x, hist.p)
plt.show()
```
You can even use `ax.plot(*hist.plot)`.
data = np.random.random(1000)
hist = enstat.histogram.from_data(data, bins=10, mode="log")

fig, ax = plt.subplots()
ax.plot(hist.x, hist.p)
plt.show()
```

You can even use `ax.plot(*hist.plot)`.

## Installation

Expand All @@ -86,7 +88,7 @@ You can even use `ax.plot(*hist.plot)`.
- Using PyPi

```bash
pip install enstat
python -m pip install enstat
```

## Disclaimer
Expand Down

0 comments on commit d23c16d

Please sign in to comment.