Diysb Tools

チャンクリスト

リストを固定サイズのチャンクに分割するための、世界で最もシンプルなブラウザベースのユーティリティです。このツールは、入力項目を分割し、順番にチャンクにまとめ、オプションで未完了のチャンクを埋め込み、カスタムセパレータとラッパーを使用して出力をフォーマットします。データの整理、バッチ処理、構造化リストの作成に最適です。カスタムセパレータ、ラッパー、チャンクオプションをサポートしています。

リストツール
入力リスト
グループ化された出力
ツールオプション
入力項目セパレータ
シンボル分割を使用
単一の文字を使用して入力項目を分割
正規表現分割を使用
正規表現を使用して入力項目を分割
入力項目を分割するために使用する区切り記号または正規表現
グループサイズと出力形式
グループあたりの項目数
グループ内の項目間に配置する区切り文字
グループ間に配置する区切り文字
各グループの前に追加する記号
各グループの後に追加する記号
空の項目とパディング
空の項目を無視し、結果に含めない
必要な項目数より少ない場合、最後のグループを埋める
未完了のグループを埋めるために使用する文字または値
チャンクリスト 例

Group Hexagon Coordinates

In this example, we group the coordinates of a regular hexagon. The input coordinates are given as a space-separated list "x1 y1 x2 y2 x3 y3 …". What we want to do is create vector point pairs such as "(x1, y1); (x2, y2); (x3, y3); …". To do that, we use the space character as the input coordinate separator, and to create vectors, we group them by pairs. We wrap the coordinates in parentheses, put a comma between the x and y group items, and a semicolon between individual groups.

2.5 9.33 0 5 2.5 0.66 7.5 0.66 10 5 7.5 9.33
2.5 9.33 0 5 2.5 0.66 7.5 0.66 10 5 7.5 9.33
(2.5, 9.33); (0, 5); (2.5, 0.66); (7.5, 0.66); (10, 5); (7.5, 9.33)
(2.5, 9.33); (0, 5); (2.5, 0.66); (7.5, 0.66); (10, 5); (7.5, 9.33)
入力項目セパレータ
シンボル分割を使用
単一の文字を使用して入力項目を分割
正規表現分割を使用
正規表現を使用して入力項目を分割
入力項目を分割するために使用する区切り記号または正規表現
グループサイズと出力形式
グループあたりの項目数
グループ内の項目間に配置する区切り文字
グループ間に配置する区切り文字
各グループの前に追加する記号
各グループの後に追加する記号
空の項目とパディング
空の項目を無視し、結果に含めない
必要な項目数より少ない場合、最後のグループを埋める
未完了のグループを埋めるために使用する文字または値

Chunks of Size 3

This example demonstrates grouping of list items and creates 9 groups of 3 items. The input list contains all alphabet letters (26 letters, separated by a semicolon) and the output is groups of letter trigrams. As the last group is missing one letter, we enable padding and add the underscore symbol as the padding element.

a;b;c;d;e;f;g;h;i;j;k;l;m;n;o;p;q;r;s;t;u;v;w;x;y;z
a;b;c;d;e;f;g;h;i;j;k;l;m;n;o;p;q;r;s;t;u;v;w;x;y;z
[a, b, c] [d, e, f] [g, h, i] [j, k, l] [m, n, o] [p, q, r] [s, t, u] [v, w, x] [y, z, _]
[a, b, c] [d, e, f] [g, h, i] [j, k, l] [m, n, o] [p, q, r] [s, t, u] [v, w, x] [y, z, _]
入力項目セパレータ
シンボル分割を使用
単一の文字を使用して入力項目を分割
正規表現分割を使用
正規表現を使用して入力項目を分割
入力項目を分割するために使用する区切り記号または正規表現
グループサイズと出力形式
グループあたりの項目数
グループ内の項目間に配置する区切り文字
グループ間に配置する区切り文字
各グループの前に追加する記号
各グループの後に追加する記号
空の項目とパディング
空の項目を無視し、結果に含めない
必要な項目数より少ない場合、最後のグループを埋める
未完了のグループを埋めるために使用する文字または値

Convert a List to a TSV

In this example, we use our list item grouper to convert a food list to tab-separated values (TSV). As spaces are chaotically used between the items of the input list, we use the item separating regular expression "\s+" to match them. We create a TSV with three columns (three groups), separate them with a tab character, and put newlines between the groups.

beef buns cake corn crab dill fish kiwi kale lime meat mint milk pear plum pate pork rice soup tuna tart
beef buns cake corn crab dill fish kiwi kale lime meat mint milk pear plum pate pork rice soup tuna tart
beef buns cake corn crab dill fish kiwi kale lime meat mint milk pear plum pate pork rice soup tuna tart
beef buns cake corn crab dill fish kiwi kale lime meat mint milk pear plum pate pork rice soup tuna tart
入力項目セパレータ
シンボル分割を使用
単一の文字を使用して入力項目を分割
正規表現分割を使用
正規表現を使用して入力項目を分割
入力項目を分割するために使用する区切り記号または正規表現
グループサイズと出力形式
グループあたりの項目数
グループ内の項目間に配置する区切り文字
グループ間に配置する区切り文字
各グループの前に追加する記号
各グループの後に追加する記号
空の項目とパディング
空の項目を無視し、結果に含めない
必要な項目数より少ない場合、最後のグループを埋める
未完了のグループを埋めるために使用する文字または値