Better explanation of how density works in pips?
See original GitHub issueHi there, I’m using your library which is great, but I’m trying to reduce the number of pips, and the denisty / scaling factor doesn’t seem to work intuitively. Can you help explain how it works? This is my code:
// Income slider
incomeSlider = document.getElementById('incomeSlider');
noUiSlider.create(incomeSlider, {
start: CONST.defaultIncome,
step: 1000, // Slider moves in increments
connect: "lower",
range: { // Slider can select range
'min': 20000,
'max': 150000
},
pips: { // Show a scale with the slider
mode: 'steps',
density: 50, // <-- it doesn't seem to matter what this value is, nothing happens
filter: function ( value, type ) {
return ((value % 10000) ? 0 : 2);
},
format: {
to: function ( value ) {
return (value + "").slice(0, -3) + 'k';
},
from: function ( value ) {
return value.replace('k', '000');
}
}
}
});
And it ends up looking like this, with too many pips in between:
I’ve tried setting the density value to 0.5 all the way to 2000 and nothing seems to change.
Issue Analytics
- State:
- Created 8 years ago
- Comments:7 (1 by maintainers)
Top Results From Across the Web
Predicted Interval Plots (PIPS): A Graphical Tool for Data ...
In this article, we reaffirm the importance and usefulness of this innovative approach and introduce a graphical summary, predicted interval plots (PIPS), ...
Read more >The Practice Integration Profile (PIP 2.0) a Tool to Measure ...
In this example, the idea is that “fully Integrated” practices have MORE integration than “collocated” practices. But does MORE integration mean ...
Read more >Calculate Crude Oil Lot Size - How to Read Oil Pips?
A recent article showed how oil trading works and how to calculate gold pips. ... Its grade is light crude oil due to...
Read more >PIP manual - WUR
As explained in section 1.1 the PIP approach aims “to build a solid foundation for sustainable change towards enhanced food production and good...
Read more >PIPS II - Materials Characterization Facility
The precision ion polishing system (Gatan PIPS™) II is an Ar + ion mill system ... (DM) software for review and analysis while...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Added. Will be in the docs next time I push an update.
Thanks for the info, airtonix!
Now if only there could be a split pip density to match the split numeric density. For example: