Icon sets in result...

Clear all

# [Solved] Icon sets in result table? Is it possible?

Page 1 / 2
Posts: 4
Customer
Topic starter
Active Member
Joined: 9 months ago

In Excel, you can use Icon sets to create the cells in this image.  Is this even possible in Analytica?

Topic Tags
6 Replies
Posts: 17
Moderator
Member
Joined: 11 months ago

How's this look?

Here is the model that produced this:

The main work was obtaining the icon images. I did that as follows.  I created 3 constant variables, which I named Icon_for_decrease, Icon_for_increase and Icon_for_no_change.  Then I used SnagIt (a program from TechSmith) to copy the image of each arrow from the image you posted (The snip it tool built into Windows would work fine for this as well). When doing the screen grab, I selected a rubber band rectangle around one arrow in your image, and then I clicked in the Definition of one of these constants and selected Paste (Ctrl+V).  After repeating that 3 times, I had the three icon images.

My model creates some random data for demonstration. The Cell icons are created by filling in the Cell Format Expression as follows:

Posts: 4
Customer
Topic starter
Active Member
Joined: 9 months ago

Wow. I didn't expect that. Very cool. I like how your arrow shows the day's change while the number shows today's price. Perfect.

I'm sure I'm pressing my luck, but since that was possible, is it possible to put sparklines in result table cells, like this?

Posts: 17
Moderator
Member
Joined: 11 months ago

I extended the previous example model to get this:

I had to add a time dimension (the index Historic_date), and I simulated some random data over a 14 day period. For the spark line, I did not use a Cell Format Expression -- instead, it is a straight image -- i.e., the result of the computation for the corresponding cell is an image -- the spark line. The expression to compute the sparkline image is just:

Sparkline(Price, Historic_date)

where Price is indexed by Stock and Historic_date.  Because this is a new variable, I had to repeat the Cell Icon expression for the new variable, and I added an IF so that it placed the icons only in the first column.

Here is the new example model:

The Sparkline here is a UDF that is included with the model. We could use a library (that someone shares with everybody) that has different sparkline types implemented as UDFs.

Posts: 5
Customer
Eminent Member
Joined: 11 months ago

Why does the arrow go up for Stock B?  From the sparkline, it looks like the price dropped. Shouldn't that be a down arrow?

Page 1 / 2
Share:
Scroll to Top