Public
Edited
Feb 10, 2024
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
numberOfSets = gotchis.filter(x=>x.modifiedRarityScore < x.withSetsRarityScore).length
Insert cell
numberOfWearables = gotchis.filter(x=>x.equippedWearables.some(number => number > 0)).length
Insert cell
numberOfGotchis = gotchis.length
Insert cell
topGotchis = gotchis.sort((x,y)=> y.withSetsRarityScore - x.withSetsRarityScore).splice(0, 7500)
Insert cell
brsTopMap = makeMap(topGotchis, "withSetsRarityScore")
Insert cell
brsTopArray = Object.keys(brsTopMap).map(key => {return {brs: key, numberOfGotchis: brsTopMap[key]}})
Insert cell
position = getPosition(606, brsTopMap)
Insert cell
getPosition = (gotchiBrs, brsMap) => {
let count = 0;
let result = ""
Object.keys(brsMap).sort((x,y)=>(y-x)).forEach(key=> {
if(key <= gotchiBrs){
result = count + " - " + (count+brsMap[key])
}else{
count = count+brsMap[key]
}
})
return result
}
Insert cell
brsTopArray
Type Table, then Shift-Enter. Ctrl-space for more options.

Insert cell
Insert cell
Insert cell
ownerCountArray = Object.keys(ownerCountMap).map(key=> {return {gotchis:+key, users: ownerCountMap[key], total: key*ownerCountMap[key]}})
Insert cell
ownerCountArray
Type Table, then Shift-Enter. Ctrl-space for more options.

Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
numberOfSets
Insert cell
gotchisWithSets
Type Table, then Shift-Enter. Ctrl-space for more options.

Insert cell

One platform to build and deploy the best data apps

Experiment and prototype by building visualizations in live JavaScript notebooks. Collaborate with your team and decide which concepts to build out.
Use Observable Framework to build data apps locally. Use data loaders to build in any language or library, including Python, SQL, and R.
Seamlessly deploy to Observable. Test before you ship, use automatic deploy-on-commit, and ensure your projects are always up-to-date.
Learn more