select2 - expandable hierarchical levels? - jquery-select2

select2 is able to display hierarchical JSON data, but for a large taxonomy (~3000 elements & 9 levels of depth) it would be ideal to have expandable levels, so by default it only shows 'level_1' elements instead of all ~3000 elements, where it could expand to further levels by clicking on a '+' sign and contract by clicking on a '-' sign.
Is this currently possible?
If not, can anybody suggest what would be the best approach to extend select2 to achieve this functionality?
Thanks.

Related

Extracting multiple sections of text from google sheets cell

I'm trying to grab a subset of covid data from a cell in google sheets that contains a lot of superfluous data.
Specifically, the LDH vaccine information tab here has a tab containing "Vaccination by Gender by Parish" which has two things repeated 64 times: A line containing information on total series initiated and completed per parish, and a chart showing the percentage breakdowns by gender for that parish.
I'm importing this tab by copy/pasting into a google form (splitting it in 2 halfway through to get around the character limit). It returns a massive cell (or, two cells rather) containing 32(x2) instances of both the lines containing parish vaccine data and several lines containing the chart data.
Is there a way I'm not seeing to create an array formula that will isolate the two segments? I don't need the gender breakdown information, just the top-line numbers per parish. If I can get the top-line numbers into a separate cell together, I can use a split function on them, but can't separate everything correctly using the split function from a single cell.
This is the shortest of three lists/charts that display the information as a raw string (on the front-facing side, which I need to use because other people will be inputting this data into the sheet).
Edit: Here's a viewable version of the sheet.
To get to the correct tab, click "Vaccination Information" at the top of the ArcGIS dashboard. Then, click the left arrow at the bottom of the dashboard until it displays "Vaccination by Gender by Parish."
Since it is not possible to use automatic import using formulas and you have to use copy-paste, you can get the result you want faster this way.
Copy from the site and paste the data on the sheet.
Filter and remove unnecessary rows.
Split the text into columns using the "-" separator.
Search and replace, remove text and spaces from the data columns.

DataStudio Question with Google Sheets- Add commas, add percentage point

I am creating a Data Studio report using Google Sheets for my data. I am trying to add numbers (ex 1,234) and I need to keep the commas in the DataStudio report. How do I do that? DataStudio keeps removing the commas.
I am also adding percentages (ex 1.234%) and I need it to be 3 percentage points but DataStudio is only adding 2. How do I do that?
Thank you so much!
I'm not sure if you just want to change the dot/comma with something different, or if they're just hidden. If they're just hidden, you can force them to unhide in the table setting a value for the field "Decimal precision" in the "Style" tab.
But if you really want to change the dot/comma behavior, you must understand that, in DataStudio, dots and commas follows the user regional preferences, and there's no simple way to customize this (actually, the best you can do is to treat the field as text and force the symbol you want to use).
Notice that in USA and some other countries, dots are used for decimal separation and commas are used as thousand separator. In my country, Brazil, we use the opposite, and other symbols/configurations exists around the globe.
I prefer to use Google in US English because I don't like translated menus. However, I know that my users usually set their accounts to Brazilian Portuguese, so when they open the dashboard made by me, it'll be displayed using their personal preferences.
So if you just want to adjust the formatting to your regional preference, there's nothing you need to do. Just assure your Google account and your users are set accordingly.
But if you really want to force the appearance of a number to a specific need, as I said, you'll need to convert it to text and format by yourself.
I fixed this issue by deselecting "compact Numbers" in the Style Tab for the data.

sumif function in excel to display percentage based on text

I am attempting to display a progress percentage in a single cell based on the choice of "completion" from a data validation list that spans multiple columns and cells.
I have attached a screen grab that will hopefully better explain. I would like the "Overall status cell (B3) to display the percentage of "Completes" that will track overall progress of requirements.
I have narrowed to a "sumif" function based on research and former templates but cannot achieve the desired result. Any help would be excellent. Thank you in advance.
You would want to do a =(COUNTIF(C5:C100, "Completed")/COUNTA(C5:C100)).
Obviously, you might want to change the range.
E2A: =SUMIF adds numbers together. Because you're looking at Text, you'll want to do a =COUNTIF and =COUNTA.

UI-GRID Single Input Filtering

Whats the best way to handle grid filtering with one input. Is there a simpler way then dealing with it this way:
http://ui-grid.info/docs/#/tutorial/321_singleFilter
I also want to filter with every keystroke, not click a button.
Thanks
If you are looking at filtering on multiple columns, thats probably the best way. To make it filter on every key stroke, you can add a "ng-change" to the text input and call the filter function as in the example.
<input ng-model='filterValue' ng-change='filter()'/>
if you have a large dataset and you filter on every key stroke, there will be performance lag unless you handle it properly inside the filter function.

What features are the most important for data-bound grid controls

Certain features for data-bound grid controls are a given and should be available in any grid. Like rows and columns (other layouts are possible in many) and checkboxes for boolean values with text representation for other values. But many grid controls offer a cacophony of features that may not be applicable to all of the use cases. Some of these are:
Multi-level data, with master rows that can be expanded to reveal detail rows. Potentially, these detail rows can have different columns and potentially these detail rows can be expanded to show additional detail levels.
Drag-and drop grouping.
Column reordering.
Theming/skinning.
Customisable row layout, where rows don't need to be composed of a line of cells but can appear like an entry card or something similar.
Editing in general - I often use custom-built editors instead and use the grid for display only.
Customisable editors that can be replaced with pretty much anything the application developer can think of.
In-grid filtering, sorting or any kind of manipulation that could also be done on the data independently of the grid.
Footers with automatic summary of given fields.
Extensive control over formatting.
I know that most of these features are useful to have in some circumstances, but which of these (or any other features you can think of) do you think any modern data-bound grid should be able to do to be useful in your applications?
Additionally:
Unbound columns to enable runtime calculated values
Rows and columns freezing (excell like - visible always regardless of scrolling)
Grouping several columns together into tree like structure for columns. Only leaves are data bound columns. I'm sure I miss some good English word for this feature.

Resources