Compare data#
In this example, we compare data from different manufacturers for common ball-end string types:
plain steel
phosphor bronze
nickel-wound
import pandas as pd
from stringcalc.tension import load_data
First we load all of the available data with the load_data() function.
data = load_data()
data
| id | uw | group | gauge | group_id | |
|---|---|---|---|---|---|
| 0 | DA:PL007 | 0.000011 | D'Addario - Acoustic or Electric Guitar - Plai... | 0.007 | DA:PL |
| 1 | DA:PL008 | 0.000014 | D'Addario - Acoustic or Electric Guitar - Plai... | 0.008 | DA:PL |
| 2 | DA:PL0085 | 0.000016 | D'Addario - Acoustic or Electric Guitar - Plai... | 0.0085 | DA:PL |
| 3 | DA:PL009 | 0.000018 | D'Addario - Acoustic or Electric Guitar - Plai... | 0.009 | DA:PL |
| 4 | DA:PL0095 | 0.00002 | D'Addario - Acoustic or Electric Guitar - Plai... | 0.0095 | DA:PL |
| ... | ... | ... | ... | ... | ... |
| 1920 | STP:XTPL014 | 0.000043 | D'Addario (STP) - Tin Coated NY Steel | 0.014 | STP:XTPL |
| 1921 | STP:XTPL016 | 0.000057 | D'Addario (STP) - Tin Coated NY Steel | 0.016 | STP:XTPL |
| 1922 | STP:XTPL017 | 0.000064 | D'Addario (STP) - Tin Coated NY Steel | 0.017 | STP:XTPL |
| 1923 | STP:XTPL018 | 0.000072 | D'Addario (STP) - Tin Coated NY Steel | 0.018 | STP:XTPL |
| 1924 | STP:XTPL022 | 0.000107 | D'Addario (STP) - Tin Coated NY Steel | 0.022 | STP:XTPL |
1925 rows × 5 columns
Plain steel#
Plain steel ball-end strings.
group_ids = ["DA:PL", "STP:PL", "GHS:PL", "SJ:PL"]
(
data.query("group_id in @group_ids")
.pivot_table(
index="gauge",
columns="group_id",
values=["uw"],
observed=True,
)
.mul(1000)
.style
.set_caption("Plain steel")
.background_gradient(axis=1, cmap="RdBu_r")
)
| uw | ||||
|---|---|---|---|---|
| group_id | DA:PL | GHS:PL | SJ:PL | STP:PL |
| gauge | ||||
| 0.007000 | 0.010850 | 0.011943 | ||
| 0.008000 | 0.014180 | 0.015609 | 0.014185 | |
| 0.008500 | 0.016010 | 0.017623 | 0.016013 | |
| 0.009000 | 0.017940 | 0.018100 | 0.019747 | 0.017953 |
| 0.009500 | 0.019990 | 0.021590 | 0.022004 | 0.020003 |
| 0.010000 | 0.022150 | 0.022700 | 0.024382 | 0.022164 |
| 0.010500 | 0.024420 | 0.025000 | 0.026880 | 0.024436 |
| 0.011000 | 0.026800 | 0.029500 | 0.029500 | 0.026818 |
| 0.011500 | 0.029300 | 0.030800 | 0.032252 | 0.029312 |
| 0.012000 | 0.031900 | 0.034000 | 0.035114 | 0.031916 |
| 0.012500 | 0.035400 | 0.038163 | ||
| 0.013000 | 0.037440 | 0.038600 | 0.041212 | 0.037457 |
| 0.013500 | 0.040370 | 0.044437 | 0.040394 | |
| 0.014000 | 0.043420 | 0.047700 | 0.047794 | 0.043441 |
| 0.015000 | 0.049840 | 0.052800 | 0.054861 | 0.049869 |
| 0.016000 | 0.056710 | 0.059000 | 0.062423 | 0.056740 |
| 0.017000 | 0.064020 | 0.068100 | 0.070470 | 0.064054 |
| 0.018000 | 0.071770 | 0.072700 | 0.079001 | 0.071811 |
| 0.019000 | 0.079970 | 0.077200 | 0.088027 | 0.080012 |
| 0.020000 | 0.088610 | 0.084100 | 0.097537 | 0.088656 |
| 0.021000 | 0.093200 | |||
| 0.022000 | 0.107220 | 0.115900 | 0.118020 | |
| 0.023000 | 0.136500 | |||
| 0.024000 | 0.127600 | 0.143200 | 0.140460 | |
| 0.026000 | 0.149750 | 0.156800 | ||
| 0.028000 | 0.170600 | |||
Note
We multiplied uw, the unit weight (mass per unit length) [lbm/in]
by 1000 to facilitate easier comparison.
Note
Within a given row, a red cell background indicates higher values and blue lower. For example, Stringjoy plain steel strings are generally heavier than the others (red), and D’Addario original and STP are always quite close (same color). The lack of a number in a cell indicates that we don’t have data for that gauge.
Phosphor bronze#
Phosphor bronze ball-end strings.
group_ids = ["DA:PB", "STP:PB", "GHS:B", "SJ:PB"]
(
data.query("group_id in @group_ids")
.pivot_table(
index="gauge",
columns="group_id",
values=["uw"],
observed=True,
)
.mul(1000)
.style
.set_caption("Phosphor bronze")
.background_gradient(axis=1, cmap="RdBu_r")
)
| uw | ||||
|---|---|---|---|---|
| group_id | DA:PB | GHS:B | SJ:PB | STP:PB |
| gauge | ||||
| 0.018000 | 0.073940 | |||
| 0.020000 | 0.081060 | 0.085060 | 0.089350 | 0.079816 |
| 0.021000 | 0.089440 | 0.088655 | ||
| 0.022000 | 0.098760 | 0.099710 | 0.104530 | 0.097982 |
| 0.023000 | 0.108010 | 0.107800 | ||
| 0.024000 | 0.116820 | 0.124700 | 0.120500 | 0.116120 |
| 0.025000 | 0.126860 | 0.130390 | 0.126780 | |
| 0.026000 | 0.136400 | 0.155600 | 0.135800 | |
| 0.027000 | 0.148340 | 0.147070 | ||
| 0.028000 | 0.164400 | 0.169960 | 0.159010 | |
| 0.029000 | 0.173810 | 0.171070 | ||
| 0.030000 | 0.186600 | 0.206200 | 0.191220 | 0.183860 |
| 0.032000 | 0.210180 | 0.213900 | 0.219480 | 0.206070 |
| 0.034000 | 0.238870 | 0.243100 | 0.236440 | |
| 0.035000 | 0.253650 | 0.246920 | ||
| 0.036000 | 0.268300 | 0.261100 | 0.262130 | |
| 0.038000 | 0.293100 | 0.309330 | 0.286220 | |
| 0.039000 | 0.311250 | 0.302490 | ||
| 0.040000 | 0.314600 | 0.340600 | ||
| 0.042000 | 0.367220 | 0.359000 | 0.374510 | 0.354960 |
| 0.044000 | 0.398700 | 0.397130 | ||
| 0.045000 | 0.417510 | 0.402030 | ||
| 0.046000 | 0.386800 | 0.437130 | ||
| 0.047000 | 0.452890 | 0.435100 | ||
| 0.048000 | 0.471600 | 0.476600 | ||
| 0.049000 | 0.491510 | 0.472330 | ||
| 0.050000 | 0.500500 | 0.543540 | ||
| 0.052000 | 0.552230 | 0.510500 | 0.576400 | 0.529540 |
| 0.053000 | 0.569620 | 0.545320 | ||
| 0.054000 | 0.611600 | 0.627280 | 0.567420 | |
| 0.056000 | 0.634770 | 0.628300 | 0.676620 | 0.606660 |
| 0.058000 | 0.648000 | |||
| 0.059000 | 0.705350 | 0.772240 | 0.678020 | |
| 0.060000 | 0.730390 | 0.715400 | ||
| 0.062000 | 0.776820 | |||
| 0.064000 | 0.827800 | |||
| 0.066000 | 0.877180 | |||
| 0.070000 | 0.968330 | 1.010200 | ||
Nickel-wound#
Nickel-wound ball-end strings.
DA:NWandSTP:NW: D’Addario nickel-plated steelGHS:N: GHS Nickel Rockers (pure nickel, semi-flattened)GHS:DY: GHS Boomers (nickel-plated steel)SJ:N: Stringjoy nickel (“Signatures”; nickel-plated steel?)SJ:PN: Stringjoy pure nickel (“Broadways”)
group_ids = ["DA:NW", "STP:NW", "GHS:N", "GHS:DY", "SJ:N", "SJ:PN"]
(
data.query("group_id in @group_ids")
.pivot_table(
index="gauge",
columns="group_id",
values=["uw"],
observed=True,
)
.mul(1000)
.style
.set_caption("Nickel-wound")
.background_gradient(axis=1, cmap="RdBu_r")
)
| uw | ||||||
|---|---|---|---|---|---|---|
| group_id | DA:NW | GHS:DY | GHS:N | SJ:N | SJ:PN | STP:NW |
| gauge | ||||||
| 0.016000 | 0.078200 | |||||
| 0.017000 | 0.055240 | |||||
| 0.018000 | 0.062150 | 0.068900 | 0.074240 | 0.080930 | 0.061926 | |
| 0.019000 | 0.069470 | |||||
| 0.020000 | 0.074950 | 0.089300 | 0.093260 | 0.087300 | 0.074003 | |
| 0.021000 | 0.082930 | 0.082453 | ||||
| 0.022000 | 0.091840 | 0.099100 | 0.102400 | 0.096050 | 0.095950 | 0.091392 |
| 0.024000 | 0.108570 | 0.101800 | 0.120200 | 0.114850 | 0.114050 | 0.108270 |
| 0.025000 | 0.118500 | |||||
| 0.026000 | 0.126710 | 0.124000 | 0.152800 | 0.137740 | 0.137040 | 0.126580 |
| 0.028000 | 0.146660 | 0.128300 | 0.169500 | 0.159790 | 0.159090 | 0.145400 |
| 0.030000 | 0.172360 | 0.163400 | 0.182900 | 0.181040 | 0.180340 | 0.170340 |
| 0.032000 | 0.193470 | 0.189600 | 0.218600 | 0.208180 | 0.207520 | 0.190210 |
| 0.034000 | 0.215900 | 0.233900 | 0.248500 | 0.231920 | 0.231220 | 0.211290 |
| 0.036000 | 0.239640 | 0.236500 | 0.278600 | 0.248880 | 0.248180 | 0.233590 |
| 0.037000 | 0.248190 | |||||
| 0.038000 | 0.264710 | 0.265500 | 0.312800 | 0.281100 | 0.280400 | 0.257100 |
| 0.039000 | 0.279320 | 0.272330 | ||||
| 0.040000 | 0.307600 | 0.323400 | 0.308380 | 0.307580 | 0.288060 | |
| 0.042000 | 0.322790 | 0.312200 | 0.370100 | 0.346250 | 0.345450 | 0.314050 |
| 0.044000 | 0.351820 | 0.321500 | 0.417400 | 0.372250 | 0.371350 | 0.341260 |
| 0.046000 | 0.382160 | 0.380600 | 0.440400 | 0.401080 | 0.400180 | 0.369690 |
| 0.048000 | 0.413820 | 0.405200 | 0.499900 | 0.437380 | 0.436480 | 0.399320 |
| 0.049000 | 0.430140 | 0.414590 | ||||
| 0.050000 | 0.470900 | 0.533200 | 0.478770 | 0.477870 | 0.430170 | |
| 0.052000 | 0.481090 | 0.478800 | 0.564000 | 0.507030 | 0.506130 | 0.462230 |
| 0.054000 | 0.538380 | 0.492000 | 0.602500 | 0.557340 | 0.516170 | |
| 0.056000 | 0.575980 | 0.659000 | 0.676200 | 0.603130 | 0.551290 | |
| 0.058000 | 0.673600 | 0.759000 | 0.640310 | |||
| 0.059000 | 0.641910 | 0.618170 | ||||
| 0.060000 | 0.665420 | 0.879100 | 0.752700 | 0.687620 | 0.641430 | |
| 0.062000 | 0.706970 | 0.747200 | 0.680320 | |||
| 0.064000 | 0.749840 | 0.798890 | 0.720420 | |||
| 0.065000 | 0.749010 | |||||
| 0.066000 | 0.798890 | |||||
| 0.068000 | 0.846140 | 0.846140 | 0.817240 | |||
| 0.070000 | 0.893040 | 0.886700 | 0.922560 | |||
| 0.072000 | 0.941240 | 0.962390 | ||||
| 0.074000 | 0.988690 | 1.024200 | 0.949480 | |||
| 0.080000 | 1.150110 | 1.211000 | 1.160000 | |||
| 0.085000 | 1.337000 | |||||
| 0.090000 | 1.502800 | |||||
| 0.095000 | 1.776600 | |||||