Multiple bubblemaps on button click same code different datas

I have included the clustered circle also in the same notebook as my bubble map (below it) but the clustered circles appear only on the top left corner and i think the x,y and r not currently defined. Can i get some help bubble and cluster

Thank you .

updated map
I have managed to plot the clustered bubbles, but have not been able to separate the groups for cluster bubble according to my CSV and make it read my data.

1 Like

Hello @mcmcclur and @aaronkyle and everyone,

I have done a few upgrades in the cluster bubble but still it is somehow not working properly, namely when it comes to show data on mouse hover and the size of the bubbles. Please do have look and i would love some suggestions. The new chart : clustercontinents

1 Like

I have almost done everything in this clustered bubble, except I am unable to change the size of bubbles as per button click. The size remains the same as per one initially implemented parameter and unfortunately does not change with the radio button. I would appreciate some help to change the radius as per button click. Here is the new link : clusterbubbles

Looks pretty good to me! I see the chart regenerate on click, and the values in your mouseover are changing. Is your concern that the generated chart looks the same each time? Could it be how ‘data’ are specified in your ‘pack’ function?

Hi @aaronkyle . Yes everything is working fine except the bubble size does not somehow change on button click.

Something fishy is going on my code. If i change the code to change the bubbles size per button click ,the bigger bubbles move out of the window frame and if i use the same code as now , the bubbles won’t change.

If I am reading everything correctly, it looks like the data you reference in the pack function is static, which is why it’s not changing on click. You’ll need to figure out how to call into the data referenced in the pack function to change so that it only reflects the specific attributes your selecting with the input. I am not too familiar with how the data are organized to be able to de-construct and re-construct it (it’s above my level of JS mastery for the moment), but it looks like that’s where you’re hitting issues.

1 Like

Thanks, Aaron.
I have a question though, is there a way to get the name of the selected radio button on mouse hover. I am getting the value, which is nice, but if I could get the name of the selected parameter before the value, it would be easy for the users to see which value is currently being projected.

Nevermind,
I added it :slight_smile:

1 Like

Updated Map
New updated map. Is there a way to add force simulation here, so the bubbles do not overlap?

I have made some changes in the Bubble Map and wanted to add some new features.
How can I let users add their own data set to my World Bubble Map and plot the bubbles with the new set of added data based on geolocation? Since I have manually edited the content of my dropdown menu, will it be possible to make the dropdown menu generate names automatically as per newly added datasets? (I know this will only be possible if the newly added datasets have the same structure as my data) A link to what I have done so far: Bubble Map

Hi! Just a note to say that I am impressed with your perseverance and the increasing sophistication of the notebooks you are sharing. I see that you figured out the force settings so that you no longer have overlapping bubbles. The zoom function is working nicely, too. I regret that you’ve passed a point where I can offer more than cheerleading - but cheers indeed to you! Thank you for keeping us posted and I hope someone can respond. I’ve found from experience that it sometimes helps to start a new topic when you’re looking for continued guidance… especially if you can pin down more concretely where you’ve tried something that doesn’t work and clarify where your attempts were not successful. Glad to have you in the community!

1 Like

Hello Aaron, thank you. I still have some issues and will open up a new discussion and also post it here :

I have created a second map where users can use their own set of data to plot the bubbles. Although, it will only work if the Country Code of uploaded .CSV data is the same as ISO_A2 (Country Code)from the .JSON file used in my Notebook. There are some issues I could not resolve. Mainly 1 . Some countries appear on the top left corner of the map which is not actually correct (the second map should actually plot the countries like the first map as both map has same longitude and latitude) 2. The same zoom function is working for the first map but not for the second map (that is kind of confusing me ) 3. Will it be possible to generate Input buttons automatically from the uploaded file or should it be done manually everytime . If i could get some help and suggestions it would be so great . I have included a dummy data in my notebook (in the data pane - File Attachments) which can be used to test the second map . Here is the link : Bubble Map

This issue has been solved !!