Skip to content

Commit

Permalink
fix typo readme
Browse files Browse the repository at this point in the history
  • Loading branch information
Thomas Bury committed Jun 11, 2021
1 parent 1fdd4d9 commit b95c60e
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 11 deletions.
17 changes: 6 additions & 11 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -68,14 +68,15 @@ I'll refer to the [The misuse of colour in science communication](https://www.na

<td align="left"><img src="pics/choosing-cmap.png" width="500"/></td>

## Choosing the color map for a given type
## Get the matplotlib cmap

You can get all the available color maps as:

```python
plt_cmap_obj = sc_map.get_mpl_color_map()
```

## Choosing the color map for a given type

Get the color maps for a given type

```python
Expand Down Expand Up @@ -181,15 +182,8 @@ plt_cmap_obj = sc_map.get_mpl_color_map()
We can perform exactly the same fix for diverging, circular, miscellaneous and qualitative color maps. Let's take a diverging color map as an illustrative example:

```python
# fixing the color map, using the same minimal lightness (lift=None),
# not normalizing to bitone and
# smoothing the chroma
sc_map.unif_sym_cmap(lift=None,
bitonic=False,
diffuse=True)

# re-assess the color map after fixing it
f=sc_map.assess_cmap(figsize=(22,10))
div_map = sc.ScicoDiverging(cmap='vanimo')
f=div_map.assess_cmap(figsize=(22,10))
```

the original color map is as follows
Expand All @@ -209,6 +203,7 @@ div_map = sc.ScicoDiverging(cmap='vanimo')
div_map.unif_sym_cmap(lift=25,
bitonic=False,
diffuse=True)
f=div_map.assess_cmap(figsize=(22,10))
```


Expand Down
Binary file modified pics/hawaii-fixed.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified pics/hawaii.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified pics/vanimo-fixed.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified pics/vanimo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit b95c60e

Please sign in to comment.