Labeling your FBA products

Has anyone here used 2D Transit or Wizard software for labeling FBA inventory? Amazon recently upped its fees by 50% (or 100% during the Christmas season) for manually checking in box contents, so we're revisiting how we handle this. The alternatives to paying the fee are that you can either upload a box contents list to Seller Central, or you can label your box with a scannable box contents label. We had some trouble with the uploading method, because it was easy to make mistakes, and we'd…

Labeling your FBA products

labeling – Improving label collisions for Tree/Graph?

Historically, MMA has never handled label collisions well, but recently they added some improvements here via things like Callout. I want to fix ImageSize but still see as much as possible (by tooltipping a minimally set of vertices).

Here’s two examples of the problem:

enter image description here

enter image description here

Unfortunately, Callout doesn’t work in Graphics but it does on ListPlot type functions… any ideas?

charts – Labeling the bars in a stacked BarChart

I have the following data, which shows the number of events by day of the week (Sunday through Saturday) and hour of the day (00 through 23):

  data={<|0 -> 2200, 1 -> 300, 2 -> 100, 3 -> 50, 4 -> 150, 5 -> 1850, 
  6 -> 2450, 7 -> 2600, 8 -> 3050, 9 -> 4400, 10 -> 5550, 11 -> 8450, 
  12 -> 7650, 13 -> 7750, 14 -> 6750, 15 -> 6350, 16 -> 5250, 
  17 -> 4600, 18 -> 3700, 19 -> 2800, 20 -> 2700, 21 -> 2650, 
  22 -> 2500, 23 -> 1950|>, <|0 -> 1750, 1 -> 100, 4 -> 300, 
  5 -> 2500, 6 -> 3100, 7 -> 7350, 8 -> 10550, 9 -> 5900, 10 -> 7150, 
  11 -> 7350, 12 -> 7850, 13 -> 7500, 14 -> 6300, 15 -> 6900, 
  16 -> 9050, 17 -> 8150, 18 -> 3800, 19 -> 3000, 20 -> 2450, 
  21 -> 2450, 22 -> 2250, 23 -> 2150|>, <|0 -> 1450, 1 -> 50, 2 -> 50,
   4 -> 650, 5 -> 2500, 6 -> 3050, 7 -> 7700, 8 -> 10450, 9 -> 6400, 
  10 -> 8250, 11 -> 8050, 12 -> 8450, 13 -> 8250, 14 -> 7200, 
  15 -> 7800, 16 -> 9600, 17 -> 9100, 18 -> 4400, 19 -> 3200, 
  20 -> 2700, 21 -> 2550, 22 -> 2450, 23 -> 2200|>, <|0 -> 1650, 
  1 -> 150, 2 -> 100, 4 -> 750, 5 -> 2550, 6 -> 3050, 7 -> 7650, 
  8 -> 11300, 9 -> 7100, 10 -> 7750, 11 -> 9350, 12 -> 9250, 
  13 -> 8000, 14 -> 7950, 15 -> 7900, 16 -> 9500, 17 -> 9150, 
  18 -> 4900, 19 -> 3600, 20 -> 2950, 21 -> 2650, 22 -> 2550, 
  23 -> 2350|>, <|0 -> 1650, 1 -> 100, 2 -> 50, 3 -> 200, 4 -> 700, 
  5 -> 2550, 6 -> 3050, 7 -> 7350, 8 -> 11150, 9 -> 7200, 10 -> 8150, 
  11 -> 8150, 12 -> 8400, 13 -> 8100, 14 -> 7400, 15 -> 7900, 
  16 -> 9800, 17 -> 9100, 18 -> 4750, 19 -> 3550, 20 -> 2850, 
  21 -> 2750, 22 -> 2450, 23 -> 2100|>, <|0 -> 1800, 1 -> 50, 
  2 -> 100, 4 -> 900, 5 -> 2500, 6 -> 3050, 7 -> 7050, 8 -> 9800, 
  9 -> 6450, 10 -> 7750, 11 -> 8650, 12 -> 9350, 13 -> 8750, 
  14 -> 7450, 15 -> 8250, 16 -> 9100, 17 -> 9550, 18 -> 6100, 
  19 -> 4800, 20 -> 3800, 21 -> 3450, 22 -> 3100, 
  23 -> 2550|>, <|0 -> 2250, 1 -> 350, 2 -> 150, 3 -> 100, 4 -> 150, 
  5 -> 2250, 6 -> 2550, 7 -> 2500, 8 -> 3500, 9 -> 4350, 10 -> 5200, 
  11 -> 6900, 12 -> 6600, 13 -> 6600, 14 -> 6150, 15 -> 6350, 
  16 -> 5650, 17 -> 6200, 18 -> 5400, 19 -> 4850, 20 -> 3750, 
  21 -> 3850, 22 -> 3400, 23 -> 2950|>}

I’ve created the following stacked BarChart. Each bar is a day of the week.
ChartLabels->Automatic labels the hours within each bar, but I’d also like to label the individual bars themselves as Sunday, Monday, Tuesday, etc.

BarChart(data, ChartLabels -> Automatic, 
 ChartLayout -> "Stacked", Joined -> True, ImageSize -> Large, 
 FrameLabel -> {Style("Day of Week", Bold, 12, Blue), 
   Style("Volume", Bold, 12, Blue)}, Frame -> True)

enter image description here

I.e., I’d like labels that are specifically associated with each bar, as seen below. But if I use ChartLabels to specify the days of the week, I loose the hour labeling. I want to keep both. How do I do that?

dow = System`DateObjectDump`$DaysOfTheWeek;
BarChart(data, ChartLabels -> {dow, None}, 
 ChartLayout -> "Stacked", Joined -> True, ImageSize -> Large, 
 FrameLabel -> {Style("Day of Week", Bold, 12, Blue), 
   Style("Volume", Bold, 12, Blue)}, Frame -> True)

enter image description here

accessibility – Accessiblity and labeling multiple buttons

I’m working on a mobile app. I have a list with multiple groups and at the end of each group, there are some buttons. I’m not sure what the screen reader should say when focusing on the buttons.

The groups are something like this:

Name | Score | Increase | Decrease | Info

Increase, decrease and info are the buttons to increase, decrease the score and info opens a details page. The list will have anywhere from one to many groups (I don’t expect there to be more than 10).

When each group of the list is focused, it reads the name and score together. So as you move across a group it reads:

“Name. Score” and then the buttons, “Increase”, “Decrease, “Info”

My question is whether it should instead be:

“Name. Score” and then “Name. Increase”, “Name. Decrease” and “Name Info”

Is it too repetitive? Or is it clearer to say which button goes with which group?

Once the button is tapped, the new score is announced as “Name. Score” again.

labeling – BubbleChart with Callout

After playing with your data, I saw some strange behaviors from Mathematica 12.2.

data = {{{"MYCBP2", 7, 1.31161, 7}, {"F5", 6, 1.65189, 6}, {"IRF2BPL",
      6, 1.65189, 6}, {"DMXL1", 6, 1.65189, 6}, {"MROH2B", 6, 1.65189,
      6}, {"MACF1", 6, 1.65189, 6}, {"IRS4", 1, 1.31161, 
     1}, {"HECTD1", 6, 1.65189, 6}, {"KIAA0232", 6, 1.65189, 
     6}, {"CUBN", 8, 1.63422, 8}, {"PURB", 6, 1.65189, 6}, {"FHOD1", 
     0, 1.65189, 0}}, {{"CEP350", 7, 2.01659, 7}, {"VPS13C", 7, 
     2.01659, 7}, {"SPEN", 6, 2.01795, 6}, {"DNAH3", 7, 2.01659, 
     7}, {"ERCC2", 9, 2.78759, 9}, {"ANK2", 9, 2.78759, 9}, {"HERC1", 
     8, 2.39479, 8}, {"KRT4", 9, 2.78759, 9}, {"TYRO3", 1, 2.33592, 
     1}, {"KMT2C", 19, 6.72092, 19}, {"AKAP9", 9, 2.78759, 9}}};

I use Map to make Callout:

data2 = Map(Callout(#((2 ;; 4)), #((1))) &, data, {2})
(*Out: {{Callout({7, 1.31161, 7}, "MYCBP2"), ... }, {Callout({7, 2.01659, 7}, "CEP350"), ... }} *)

BubbleChart(data2, LabelingSize -> 30)

The chart will be plotted but with some errors and no callout
enter image description here

Solution

But If you change the bubble size of {"FHOD1", 0, 1.65189, 0} which is zero to a non-zero value for example {"FHOD1", 0, 1.65189, 0.5}, errors will disappear and everything works as expected.

enter image description here

Problem

It looks like if you set bubble size to zero in any element of your data whether it’s in Callout wrapper or not, Mathematica will not show any Callout. In Mathematica BubbleChart documentation in Details section mentioned:

The value z (bubble size) should be positive.

but it doesn’t discuss Possible Issues of non-positive values.
For example, we have two element with non-zero bubble size wrapped in Callout:

data3 = {Callout({3, 2, 2}, "test"), Callout({3, 3, 3}, "test")};

BubbleChart(data3)

enter image description here

If I add an element with zero value in bubble size, whether it’s wrapped in Callout or not, all the callouts will disappear:

data4 = Append(data3, {1.5, 2, 0});

data5 = Append(data3, Callout({1.5, 2, 0}, "test"));

BubbleChart(data4)

BubbleChart(data5)

Results of BubbleChart for data4 and data5 are the same:

enter image description here

It’s also interesting that in the example above no error raised but in your case, it did.

plotting – Labeling of 2 equations plotted in 3D plot

I want to plot Subscript((Rho), i)

Subscript((Rho), i)=1/(1 + ((-Subscript(r, 1) + 10)/(-Subscript(r, 2) + 10))^(-1/2))

Subscript((Rho), j)=1/(1 + ((-Subscript(r, 2) + 10)/(-Subscript(r, 2) + 10))^(-1/2))

in 3D plot. I have used following code:

Plot3D({1/(1 + ((-Subscript(r, 1) + 10)/(-Subscript(r, 2) + 10))^(-1/2)), 1/(1 + ((-Subscript(r, 2) + 10)/(-Subscript(r, 2) + 10))^(-1/2))}, {Subscript(r, 1), 0, 9.99}, {Subscript(r, 2), 0, 9.99}, AxesLabel-> {"!(*SubscriptBox((r), (1)))", "!(*SubscriptBox((r), (2)))", "!(*SubscriptBox(((Rho)), (i)))", "!(*SubscriptBox(((Rho)), (j)))"})

But, I cannot label

Subscript((Rho), i) and Subscript((Rho), j)
Any instruction please

plotting – Labeling cluttered vertices

I am trying to create a ConvexHullMesh plot where the vertices are labeled with their positions. I generate the ConvexHullMesh using

region = 
ConvexHullMesh[Join[pts1, pts2], Axes -> True, MeshCellStyle -> {1 -> Opacity[1, Red]}, 
MeshCellHighlight -> {2 -> Opacity[.3, Red]}, Frame -> False]

and then use

HighlightMesh[decompregion, Style[0, Directive[PointSize[0.015], Black]]] 

to highlight the vertices. Which gives me this output:

enter image description here

Now I want to additionally see the positions of the vertices. The only thing I figured out yet, was HighlightMesh[decompregion, Labeled[0, "Index"]] which provides

enter image description here

First of all, I am not able to combine the Labeled and Style command. When I simply use HighlightMesh[decompregion, Style[0, Directive[PointSize[0.015], Black]], Labeled[0, "Index"]] I get an error.

Secondly I’d like to see the positions of the points and not their label. Is this possible? And furthermore as you can see, since the vertices are cluttered one can barely read the labels. Is there some way of positioning the labels further away from the boundary and use some lines which indicate the corresponding point or some other smart solution to make it more readable? Increasing the plot size would be one step to improve it, however I also wasn’t able to do that.

Any help is highly appreciated.