Skip to content

WIP padLinear#213

Open
curran wants to merge 3 commits into
d3:mainfrom
curran:patch-3
Open

WIP padLinear#213
curran wants to merge 3 commits into
d3:mainfrom
curran:patch-3

Conversation

@curran

@curran curran commented Jun 17, 2020

Copy link
Copy Markdown
Contributor

Closes #150

Please let me know if this looks like a good direction. With some encouragement I'm happy to flesh out the PR with README updates - but first I want to confirm this direction is acceptable. Thanks for reviewing!

@curran curran changed the title WIP Expose pad from linear. WIP padLinear Jun 17, 2020
@curran curran mentioned this pull request Jun 17, 2020
@Fil

Fil commented Jul 27, 2020

Copy link
Copy Markdown
Member

It would be nice to see how this would work for other types of scales (log, sqrt…)

@curran

curran commented Feb 13, 2021

Copy link
Copy Markdown
Contributor Author

An idea from https://observablehq.com/@mbostock/inequality-in-american-cities :

function padLog(x, k) {
  return padLinear(x.map(Math.log), k).map(Math.exp);
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

Pad domain addition?

2 participants