Pre-position an item in Masonry (e.g., 2nd row and 3rd column should always be X) - jquery-masonry

Is there is a way to specify where an item should end up on a Masonry layout?
I don't mean in terms of absolute position (as you would do with stamp). I mean in terms of flow, for example: X should always be displayed on the 2nd row of the 3rd column, regardless of its actual absolute position.
I read the documentation but can't find anything to achieve that. If it does not exist, do you have some recommendations on how to go about it?

Related

Match and Conditional Formatting from Matrix Table

I am looking for some decent help with my matrix table, and is there a good or best approach to properly match dependent instances in certain matrix using drop downs.
This picture represents my matrix table (Picture 1):
As you can see there are a lot of instances, but horizontally and vertically they got the same number of "headers". Those "1`s" are representing not compatibility in my case but lets call it simply "match". That is on one sheet that is gonna be populated with some new values from time to time.
On another sheet which is actually sheet for showing the data and their compatibility possibilities is equipped with drop downs. There you got "Groups (Group1, Group2...)" in a sense of main parts and "dependent groups (AA1, BB2..)" as small components that are part of main parts. To avoid misunderstanding here you have explanations, I used for the sake of this example fictional values:
Groups aka. Main Parts
Dependent groups aka. components
As you can see beneath, is my fictional table but exactly the same concept as I should use in my real case.
I PUT AN EXPLANATION IN THE PICTURE 2 SO YOU CAN FOLLOW ALONG AND SEE EXACTLY WHERE/WHAT I DID!
What I used firstly there are =match functions, one for vertical position (A3) and one for horizontal (B4). This boolean row is done using =or(index) but reffering to the match positions as you can see. And from there I should use true/false for coloring my group boxes in a case compatibility is possible - thats all the science.
So, my question is if there is another approach to this problem? As you can see I have 3 different rows of functions at one place, or imagine if I will have more "groups" that can rise in many more rows and calculations.
Picture 2
EDITED:
This is screenshot of the original sheet, I just hid some rows that were with Infos that is reason the number is not consistent. As you can see it is almost the same as dummy example I provided above. Underneath every "box" you got three rows of calculations as I mentioned before. The two times number "2" that you see here is the position of some value that I found using =match function, one is for horizontal and another for vertical lookup. In this case it is model type, 070FX is position 2, 100FX is 3 and 200FX is 4th position in the matrix table, and so on for all the other groups. And those groups (Model, Endpoint, Gas sensor...) are defined separately on another sheet where I had to make unique list and dependent list so I can reference those to my drop down list.
EDIT Nr 4! So this formula I used for true/false:
=SUMPRODUCT(('0359-matrix'!$A$2:$A$101=F10)*(('0359-matrix'!$B$1:$CW$1=$B$10)+('0359-matrix'!$B$1:$CW$1=$C$10)+('0359-matrix'!$B$1:$CW$1=$D$10)+('0359-matrix'!$B$1:$CW$1=$E$10)+('0359-matrix'!$B$1:$CW$1=$F$10)+('0359-matrix'!$B$1:$CW$1=$G$10)+('0359-matrix'!$B$1:$CW$1=$H$10)+('0359-matrix'!$B$1:$CW$1=$I$10)+('0359-matrix'!$B$1:$CW$1=$J$10)+('0359-matrix'!$B$1:$CW$1=$K$10)+('0359-matrix'!$B$1:$CW$1=$L$10)+('0359-matrix'!$B$1:$CW$1=$M$10)+('0359-matrix'!$B$1:$CW$1=$N$10)+('0359-matrix'!$B$1:$CW$1=$O$10)+('0359-matrix'!$B$1:$CW$1=$P$10)+('0359-matrix'!$B$1:$CW$1=$Q$10)+('0359-matrix'!$B$1:$CW$1=F13)+('0359-matrix'!$B$1:$CW$1=G13)+('0359-matrix'!$B$1:$CW$1=H13)+('0359-matrix'!$B$1:$CW$1=I13)+('0359-matrix'!$B$1:$CW$1=J13))*'0359-matrix'!$B$2:$CW$101)>0
I copied only last part, or when it starts from second row..Because it is too long to write whole funciton - it cuts down automatically.
('0359-matrix'!$B$1:$CW$1=$Q$10)+('0359-matrix'!$B$1:$CW$1=$B$13)+('0359-matrix'!$B$1:$CW$1=$C$13)+('0359-matrix'!$B$1:$CW$1=$D$13)+('0359-matrix'!$B$1:$CW$1=$E$13)+('0359-matrix'!$B$1:$CW$1=$F$13))*'0359-matrix'!$B$2:$CW$101)>0
But on marked cells I am getting the same results: B22 - F22 has the same as B21 - F21 (boolean) what shouldnt be like that but to follow color, green is False, it has to be something with an array reference.
Checkout the following. A1 to E5 is the matrix that shows which pieces are incompatible (=1). The others have to be empty or 0.
In cell I8 I used the following formula (and copied it down up to I11):
=SUMPRODUCT(($A$2:$A$5=H8)*(($B$1:$E$1=$H$8)+($B$1:$E$1=$H$9)+($B$1:$E$1=$H$10)+($B$1:$E$1=$H$11))*$B$2:$E$5)
The formula result shows you the amount of incompatibilities a part has. Eg AA1 has one incompatibility with BB2 but BB2 is incompatible with 2 AA1 and CC3.
To get the TRUE/FALSE use the same formula and append >0: like =SUMPRODUCT(…)>0
For any additinonal "group" (Model, Endpoint, …) you need to add another +($B$1:$E$1=$H$12) where $B$1:$E$1 points to your matrix data and $H$12 to your selected group value.
Overview of the formula ranges:
Note that this kind of calculation can only tell the amount of incompatibilites a part has but not the names of the parts that are incompatible.
Edited horizontal version
Formula in the selected cell is
=SUMPRODUCT(($A$2:$A$5=G8)*(($B$1:$E$1=$G$8)+($B$1:$E$1=$H$8)+($B$1:$E$1=$I$8)+($B$1:$E$1=$J$8))*$B$2:$E$5)
you can pull it to the right.

Ag-Grid column on second line of row if data exists

I am looking to implement the free version of ag-grid for displaying about 1,000 records. The records have about 8 columns that will display on the first row, but I would like the 9th column to display across the entire width of the row on a second line. It would only display if data exists. Is there a way to accomplish that with Ag-Grid?
In the free version of AgGrid you have Full Width Rows. However, you cannot have a full-width-row and a regular columns-row which both access the same data. And I assume what you are looking for is a design like this:
|___|___|___|___|___|
|___________________|
|___|___|___|___|___|
|___________________|
|___|___|___|___|___|
|___________________|
So in order to have both columns and rows, you would need to duplicate the data and do something like
function isFullWidth(index) {
return index % 2 === 0;
}
Now if you want the full-width-row to be expandable/collapsable (I assume it is for some detail information that the 9th column is too small and you want to place an expand button in that column), you have to get ag-grid enterprise for the row-grouping or row-trees.
Our team also faced that problem (data not fitting in the column) and we went for the approach of putting ngx-bootstrap-tooltip in a column, so on hover (or hammer.js-gesture) you see a tooltip.

Spotfire: How to use trellis to show 4 elements: 3 years + set of records older than 3 years?

Lets say I have the data about some kind of requests.
I have column determining request's creation date.
I wish to show the requestes Trellis'ed by this date but not the standard way.
I wish all the requests with creation date older than 2013-01-01 to be grouppped in one trellis graph.
I also would like to retain the possibility to have information on both year and quarter level as it is available for typical date column.
The image below show sth similar to what I need but the Empty section comes as the last one and I need it with different label and on the left hand side rather than as it is now on the right hand side.
Any ideas ?
my suggestion is to make two visualizations. you can duplicate the one you've already created and then limit its data by editing the properties for that vis, viewing the Data page, and using the Limit data using expression field, giving an expression like [Date Column] < "2013-01-01". you'd do the same on the second vis except use an expression like [Date Column] >= "2013-01-01".
the easiest way to change (Empty) to "something" is to not leave it empty :) you can create a calculated column with the expression If([Column] is null, "Custom Empty", [Column]) and then use that on the horizontal axis. alternatively you can hide (Empty) values from a visualization by limiting the visualization by an expression like [Column] is not null.
you can adjust the order which values are shown by going to the Edit menu and choosing Column Properties. choose the column, click the Sort Order tab, select Custom Sort Order, and click Configure.

Break-Down Data in Excel without VBA (Formula Only)

Many times, I am required to provide some type of break-down to the customers - an example is shown in the attached figure.
I have a table of data ("TABLE DATA" - which is some type of pivot) + Customer provides its official form, its structure must be preserved (highlighted in yellow ). Basically, I need to separate the cost details of CODE "A" and CODE "B" into 2 separated sections.
Customer requires me to provided details for each individual Part (example shows Part A - "Break-Down Part A)
Is there anyway to put a"ITEM" from "TABLE DATA" into Code A and Code B ? the rests can be solved by Vlookup (Price, Quantity) - note: "ITEM" is non-duplicated values . Thank you very much
Number your rows in the breakout using =1 and =A1+1 and then just use the formula ="B-ITEM"&TEXT(A1,"000"). If you want to skip making a counter column you could use ="B-ITEM"&TEXT(ROW()-1,"000") to just use the current row number (minus 1 or however many you need).
If your items aren't sequentially like that, but still unique, I would recommend adding counters on the original tab similar to what you have, which would let you quickly find the 5th A or 7th B, something that counts the previous instances of your current type, and then adds 1. For Row 6 you could do =COUNTIF(A$1:A5,A6)+1.

Hector Component Equality

I was reading the following link, which provides an introduction to composite columns and I had few doubts, specially regarding the usage of ComponentEquality.EQUAL and ComponentEquality.GREATER_THAN_EQUAL.
In the following example:
Composite start = compositeFrom(startArg, Composite.ComponentEquality.EQUAL);
Composite end = compositeFrom(startArg, Composite.ComponentEquality.GREATER_THAN_EQUAL);
start.addComponent(1,"CA",Composite.ComponentEquality.EQUAL);
end.addComponent(1,"CA",Composite.ComponentEquality.GREATER_THAN_EQUAL);
I'm unable to comprehend why the end component needs GREATER_THAN_EQUAL as equality component.
An explanation with example would be really helpful
The way a slice query works in cassandra is that you specify a start column and an end column(limit/isDescending flag too but that is irrelevant here). One way of querying for your use case would be to pass the complete (Composite)column name for the first composite column that starts with US:CA and the last composite column that starts with US:CA. However, you do not know this in advance.
The good thing about slice queries is that the start and end columns do not need to be actual column names. Since column names are always sorted, if the start column in the slice query does not exist, cassandra will start from the next column greater than the start column provided.
So, we need to construct a start column and an end column for your query. As described in the link, a composite object has an e-o-c bit. This bit is used by slice queries.
A composite column has several components. Each component has the e-o-c bit. When a component has this bit set to Equal, Cassandra moves on to look at the next component. When a component has this bit set to GREATER_THAN_EQUAL, Cassandra will keep on looking at columns, until it finds something whose respective component is not equal to the component we are looking for.
So, now consider the example in the link: We want to do a slice query on a column family which has a composite comparator with three components. We want to get all columns where the first component is US and the second component equal to CA.
We have to create a start column and an end column. The start column will have two components(both with EQUAL as e-o-c) and the end column will have first component as EQUAL and the second component as GREATER_THAN_EQUAL. This will match all the columns whose first component is US and second component is CA.
If you set this bit to EQUAL, a slice query will match the first column it finds with start component is equal to 'CA'. This is fine but Cassandra also needs to know the end column for the slice query. For this, it will look at the end composite you provided.
Hope this helped.
EDIT: To make explanation better

Resources