Difference between revisions of "User talk:Charlesnepote"
Jump to navigation
Jump to search
(Test with ExternalData) |
(Data quality issue with percentage) |
||
(5 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
− | I'm also going to use this page for some tests. | + | I'm also going to use this page for some tests with https://www.mediawiki.org/wiki/Extension:External_Data . |
{{#get_web_data: | {{#get_web_data: | ||
Line 9: | Line 9: | ||
}} | }} | ||
+ | == Simple test == | ||
Products with funny barcodes: | Products with funny barcodes: | ||
{| class="wikitable" | {| class="wikitable" | ||
Line 14: | Line 15: | ||
{{!}}- | {{!}}- | ||
{{!}} {{{product}}} | {{!}} {{{product}}} | ||
+ | }} | ||
+ | |} | ||
+ | |||
+ | == Test with "product" macro == | ||
+ | Products with funny barcodes: | ||
+ | {| class="wikitable" | ||
+ | ! Code {{#for_external_table:<nowiki/> | ||
+ | {{!}}- | ||
+ | {{!}} {{Product|{{{product}}}}} | ||
+ | }} | ||
+ | |} | ||
+ | |||
+ | == Rich test chaining two requests == | ||
+ | |||
+ | {{#get_web_data: | ||
+ | url=https://world.openfoodfacts.org/api/v2/search?code={{#for_external_table:{{{product}}},}}&fields=code,product_name | ||
+ | |format=JSON | ||
+ | |use jsonpath | ||
+ | |data=code=$.products[*].code,name=$.products[*].product_name | ||
+ | |cache seconds=360 | ||
+ | |use stale cache | ||
+ | }} | ||
+ | |||
+ | Products with funny barcodes: | ||
+ | {| class="wikitable" | ||
+ | ! Code | ||
+ | ! Name {{#for_external_table:<nowiki/> | ||
+ | {{!}}- | ||
+ | {{!}} {{{code}}} | ||
+ | {{!}} {{{name}}} | ||
+ | }} | ||
+ | |} | ||
+ | |||
+ | == Data quality test == | ||
+ | |||
+ | {{#get_web_data: | ||
+ | url=https://world.openfoodfacts.org/category/vegetable-oils/nutrition-grade/b.json&fields=code,product_name&page_size=100&nocache=1 | ||
+ | |format=JSON | ||
+ | |use jsonpath | ||
+ | |data=count=$.count,code=$.products[*].code,name=$.products[*].product_name | ||
+ | |cache seconds=360 | ||
+ | |use stale cache | ||
+ | }} | ||
+ | |||
+ | {{#get_web_data: | ||
+ | url=https://world.openfoodfacts.org/category/vegetable-oils.json&fields=count&nocache=1 | ||
+ | |format=JSON | ||
+ | |use jsonpath | ||
+ | |data=count_category=$.count | ||
+ | |cache seconds=360 | ||
+ | |use stale cache | ||
+ | }} | ||
+ | |||
+ | {{#external_value:count}} of {{#external_value:count_category}} ({{#expr: ({{#external_value:count}} / {{#external_value:count_category}} * 100)round2}}%) vegetable oils with Nutri-Score B (100 products max displayed): | ||
+ | {| class="wikitable" | ||
+ | ! Name | ||
+ | ! Code | ||
+ | {{#for_external_table:<nowiki/> | ||
+ | {{!}}- | ||
+ | {{!}} {{{name}}} | ||
+ | {{!}} {{Product|{{{code}}}}} | ||
}} | }} | ||
|} | |} |
Latest revision as of 09:35, 1 October 2021
I'm also going to use this page for some tests with https://www.mediawiki.org/wiki/Extension:External_Data .
Simple test
Products with funny barcodes:
Code |
---|
7622210501240 |
4003171036249 |
0678963100206 |
6408430010998 |
4388844148840 |
4056489230403 |
23006096 |
5760466878333 |
4012824401983 |
4056489526872 |
8857124162105 |
4903333066254 |
5060250610058 |
6001108028044 |
4388844237773 |
5292705000064 |
6291002400019 |
8480000105684 |
7501020515343 |
8424790100146 |
8002469561421 |
20036188 |
4036303138467 |
4036303138481 |
4104060024931 |
4104060027789 |
4104060030772 |
4104060031533 |
4104060030796 |
4104060031304 |
4104060031427 |
4104060031649 |
4104060011184 |
4104060000041 |
4104060024726 |
4104060029196 |
8424790109040 |
8424790210029 |
8424790200037 |
8424790111012 |
8424790111005 |
8424790210036 |
8424790101341 |
8424790106025 |
5601024131111 |
5601024134136 |
5601024122522 |
5601024301231 |
40363486 |
40363028 |
40466071 |
5000181028133 |
4016241015228 |
7310865075376 |
5711953116681 |
20092016 |
7613033174667 |
7613033162220 |
7613036271868 |
7613037962215 |
7613036268882 |
7613037933017 |
7613034704436 |
7613032341640 |
7613036862295 |
7613034584236 |
7613035001848 |
7613035617216 |
7613033157776 |
7613031587339 |
7613034389398 |
7613033091391 |
5011546498492 |
5608531001043 |
5608531001036 |
0050000274444 |
0072310001770 |
0072310010925 |
5060490400051 |
8004673700320 |
4056489272410 |
3250391610389 |
3250390808411 |
3250391201327 |
40876191 |
4056489189121 |
4056489209997 |
4056489300786 |
4006952006912 |
4006952007896 |
4006952007940 |
4006952007902 |
20406561 |
4006952008121 |
4006952007421 |
4006952006943 |
4006952008169 |
4006952007049 |
7622210475411 |
7622210608741 |
8410000817911 |
7622300654177 |
7622300563523 |
7622300366827 |
7613031300655 |
8480000108487 |
8480000108128 |
8480000107480 |
7622210244864 |
20899677 |
8695077100092 |
5601175101124 |
5601050033014 |
5601175103135 |
5601244202318 |
5601244202677 |
5601244202660 |
5601244202684 |
5603722508752 |
5601244700005 |
5601244500063 |
5601244202332 |
5601244201960 |
4056489210009 |
6342462000315 |
6342462010000 |
3173286828204 |
20621483 |
4056489515951 |
5601009942121 |
5601050034516 |
5601244500070 |
0869198000137 |
29074945 |
4601576012624 |
20351168 |
4056489592402 |
5053827188531 |
3760122961876 |
5287001688047 |
4056489575375 |
4056489999515 |
4901330573041 |
4056489488194 |
6009881007614 |
4056489136354 |
8000500407394 |
3292590842345 |
4056489671442 |
3332930012073 |
8002885007480 |
8002885000573 |
4903333214327 |
5053827188876 |
20191948 |
4056489356066 |
6009881007645 |
4056489507802 |
8936119181168 |
0612322000776 |
189913891365460 |
7613031625758 |
4056489409069 |
20004101 |
4056489832737 |
4012824402614 |
4056489320456 |
5601043119022 |
5601027972735 |
3760279120171 |
5601050037838 |
4056489356172 |
7071688004614 |
8412600100325 |
3387390335217 |
4056489746911 |
4015637018904 |
5601050036985 |
3033491485756 |
7613036257183 |
8722700298182 |
5601050037869 |
4056489522799 |
20093716 |
20997038 |
8410500028206 |
4056489090069 |
8427209019558 |
20353889 |
8410022000063 |
8410022115576 |
4601075391923 |
8426904170533 |
4056489246053 |
8426904171875 |
8426904176849 |
8426904170687 |
8426904172650 |
8426904170786 |
8426904170069 |
8426904176351 |
8426904176344 |
8426904170700 |
8426904170601 |
0612322000790 |
40897677 |
8000300264388 |
4056489526889 |
4056489233725 |
4335619016514 |
4012852001209 |
20983536 |
2412126103714 |
3168930174585 |
4056489841913 |
4012852001629 |
20453459 |
5601244500162 |
5601241100006 |
5601055607029 |
5601009926091 |
7310865073556 |
8593807647223 |
5603722516764 |
5601050036251 |
4056489574408 |
5000112541007 |
4012852001049 |
0612322030087 |
3252210390014 |
20442767 |
5900852054822 |
20047214 |
8683130069073 |
5601314222208 |
5711953031885 |
4012852001735 |
4036300002648 |
4056489199861 |
9001745050283 |
8410014503329 |
4061464317543 |
3507001000161 |
5601244201984 |
3387390326468 |
3339572120005 |
42419075 |
5601241404005 |
5602691250785 |
5601511000012 |
3273221113195 |
4056489696216 |
5601050037104 |
20198107 |
5606293070123 |
5601055607005 |
5000181030938 |
5601050033762 |
8412600028605 |
20005719 |
8480000861603 |
20400811 |
5901716990621 |
4056489507765 |
4056489470717 |
5601050037272 |
7613036668378 |
4056489520542 |
4056489792475 |
3250392712525 |
20005726 |
4056489167037 |
5601050037777 |
5900020036988 |
8850389821060 |
4056489747475 |
20944575 |
3701239902123 |
20632984 |
5603722520594 |
5603729555995 |
20724696 |
4056489408932 |
5601050037289 |
20619848 |
7613032222109 |
3387390406719 |
3073780821155 |
20202392 |
20353032 |
7613036669498 |
4056489408918 |
5001705011457 |
4316268595865 |
20003548 |
5601050036909 |
4056489409052 |
5601050038132 |
20150907 |
20558123 |
20918507 |
5900020032799 |
4056489520504 |
20559625 |
20255138 |
5601050037517 |
5900020036179 |
3387390326574 |
8850389107089 |
5601163440020 |
20444006 |
8006460022004 |
8008440011121 |
20004132 |
20202408 |
5601050036268 |
5900020036162 |
7613038969510 |
8410500023652 |
4056489169819 |
20014384 |
56002621 |
3760122961760 |
20005733 |
20637682 |
20267605 |
7501059243873 |
5601511000708 |
8410500029593 |
20815394 |
20047238 |
Test with "product" macro
Products with funny barcodes:
Rich test chaining two requests
Products with funny barcodes:
Code | Name |
---|---|
20724696 | Almonds |
20267605 | Anacardi |
20005733 | Walnusskerne |
20047238 | Amestec de nuci, alune, caju și migdale |
20815394 | Fruit & Nut Mix |
20150907 | Сушени и захаросани боровинки |
40897677 | Bio-Haferflocken Zart |
20202392 | Brazil nuts |
4056489300786 | Knusper Müsli Schoko |
3252210390014 | |
20005719 | Pistaches de Californie |
20005726 | |
3387390326574 | |
3033491485756 | Hipro Fraise Framboise |
20003548 | Choco nussa |
20014384 | Cacahuètes - grillées & salées |
8000300264388 | |
20004132 | Rosii - Chooped tomatoes |
20353032 | Nussmix geröstet & gewürzt, mit getrockneten Oliven |
20621483 | Bran Flakes |
Data quality test
280 of 24556 (1.14%) vegetable oils with Nutri-Score B (100 products max displayed):
Name | Code
|
---|---|
Nutrioli | (see product 7501039120149 m) |
Crinkle Cut Oven Chips | (see product 20809973 m) |
almond extract | (see product 96081310 m) |
tame and shine spray | (see product 5012254058541 m) |
Mazola con aceite de oliva | (see product 0750894622030 m) |
Grapefruit salad | (see product 5050854467196 m) |
Naturalia Avocado Oil | (see product 0059749979702 m) |
Olive oil flavoured with chilli | (see product 01709834 m) |
castor oil | (see product 0746092298054 m) |
Butter Flavored Cooking Spray | (see product 0021130512553 m) |
Olio Extra Vergine di Oliva | (see product 8056736503294 m) |
Olio | (see product 8005305600032 m) |
Original vegetable oil spray | (see product 0040600341226 m) |
Huile de tournesol | (see product 5060463190002 m) |
Sesame oil | (see product 8210040351006 m) |
Flavored no stick cooking spray | (see product 0078742229423 m) |
Orzeszki z pieca | (see product 5900571100039 m) |
Organic Toasted Sesame Oil Unrefined | (see product 0022506165052 m) |
Huile d'olive vierge extra | (see product 3266191014623 m) |
Extra Virgin Olive Oil | (see product 9415102000833 m) |
Roasted Sesame Oil | (see product 0048002005852 m) |
Aceite de coco | (see product 7798260050233 m) |
Cooking Spray, Original | (see product 0040600215893 m) |
Sunflower oil | (see product 5904413693031 m) |
Expeller Pressed Coconut Oil Cooking Spray | (see product 0042563603854 m) |
Pure huile végétale | (see product 6046000006400 m) |
Omaar pure sunflower oil | (see product 8691313988851 m) |
Original nostick cooking spray | (see product 0051500117392 m) |
Trader joe's, coconut oil spray | (see product 00505000 m) |
Coconut oil non-stick cooking spray | (see product 0026700156182 m) |
Chill oil cooking spray | (see product 5000442008089 m) |
Virgin Sesame Oil | (see product 0749544007709 m) |
Huile vierge de colza | (see product 3770000198003 m) |
Grapeseed oil | (see product 5010251481683 m) |
Aceite de oliva virgen extra ecológico | (see product 8437010369896 m) |
Grapeseed oil | (see product 8002470028524 m) |
Organic Sunflower Oil | (see product 0749544007723 m) |
Coconut oil | (see product 0070404004522 m) |
Huile vierge tournesol | (see product 5400930006069 m) |
Olio di semi di mais | (see product 8009113031118 m) |
Haricots verts | (see product 00954464 m) |
Organic Avocado, Coconut & Safflower Oil Spray | (see product 0853807005965 m) |
Extra virgin. Koroneiko | (see product 5200126140023 m) |
Baking No-Stick Cooking Spray | (see product 0041303043035 m) |
Coconut Oil Cooking Spay | (see product 0711535509042 m) |
Roasted Hazelnut Oil | (see product 0857190000118 m) |
Healthy chef, butter cooking spray | (see product 0849607090522 m) |
Detox citron | (see product 04559757 m) |
Vegetable oil no-stick cooking spray | (see product 0041303019221 m) |
Canola oil | (see product 7460193740405 m) |
Farchioni il casolare grezzo naturale olio extra | (see product 8007153001849 m) |
Huile de maïs | (see product 0761720192122 m) |
Pure wesson corn oil | (see product 0027000650226 m) |
Bakers baking spray | (see product 0605021774000 m) |
Organic High Heat Sunflower Oil Refined | (see product 0022506117105 m) |
Tahin chiaro | (see product 8057733610039 m) |
Canola cooking spray | (see product 9415077035519 m) |
non stick cooking spray | (see product 0036800459922 m) |
Spray butter | (see product 0029000651517 m) |
Huile de sesame | (see product 4892958998227 m) |
Canola Oil Cooking Spray | (see product 0849607090515 m) |
Avocado oil | (see product 0041220414789 m) |
Urbani White Truffle Oil | (see product 8000146500046 m) |
Shoprite, vegetable oil cooking spray | (see product 0041190048625 m) |
Avocado Oil | (see product 0070404004539 m) |
Canola Oil Cooking Spray | (see product 0096619105502 m) |
Vegetable Oil Cooking Spray | (see product 0078742229416 m) |
Ghee cooking spray | (see product 0742392931172 m) |
Aceite comestible puro de canola | (see product 0096619597727 m) |
Organic Hemp Seed Oil Raw & Cold Pressed | (see product 0692752100000 m) |
Avocado Oil | (see product 7502006272298 m) |
Organic Extra Virgin Olive Oil Cooking Spray | (see product 0814314023637 m) |
Olive oil cooking spray | (see product 0041190077557 m) |
Chipotle avocado oil spray | (see product 0815074021864 m) |
Garlic Avocado Oil Spray | (see product 0815074021857 m) |
Spiced Chai Avocado Oil Spray | (see product 0815074021932 m) |
Baking Spray With Flour | (see product 0074164303624 m) |
Infused Avocado Oil Spray, Gingerbread | (see product 0815074021925 m) |
Avocado oil spray | (see product 0671635701879 m) |
Simply Cinnamon Avocado Oil Spray | (see product 0815074021918 m) |
Citrus Pepper Avocado Oil Spray | (see product 0815074021895 m) |
Lemon Dill Avocado Oil Spray | (see product 0815074021888 m) |
Chili Lime Ginger Avocado Oil Spray | (see product 0815074021901 m) |
Olio extra vergine di oliva | (see product 8024829001248 m) |
MAZOLA Óleo de Milho | (see product 7894000030029 m) |
Italian Herb Avocado Oil Spray | (see product 0815074021871 m) |
Pumpkin Spice Avocado Oil Spray | (see product 0815074022663 m) |
ELOGIATA Óleo de Algodão Elogiata | (see product 7898914796118 m) |
Avocado Oil Blend | (see product 0850687110307 m) |
Vegetable oil cooking spray | (see product 0060788070180 m) |
Sunflower oil | (see product 8681934005891 m) |
SÉSAMO REAL Óleo de Gergelim | (see product 7898269631539 m) |
Roasted peanut oil | (see product 0854259005046 m) |
Organic Extra Virgin Olive Spray Oil | (see product 0854259005183 m) |
LIZA Óleo de Girassol Liza | (see product 7896036090664 m) |
Avocado Oil | (see product 0857190000088 m) |
COOPERNATURAL Óleo de Soja Orgânico | (see product 7898916031323 m) |
Organic Extra Virgin Olive Oil Cooking Spray | (see product 0888670096222 m) |
Huile de noix de coco pure | (see product 0001973000015 m) |
Olive cooking spray | (see product 0038024206559 m) |