將 x 和 y 值從文字檔案匯入 jmp 表你好,
讀取文字檔案中的每一行並將每個字串作為 jmp 資料表中的單獨行匯入
進階統計建模資料存取大規模客製化回覆:將文字檔案中的 x 和 y 值匯入 jmp 表並建立晶圓圖謝謝賈莫。
回覆:將文字檔案中的 x 和 y 值匯入 jmp 表並建立晶圓圖這是完整的範例,它使用關聯數組來儲存有關晶圓的資訊並從文字檔案建立 jmp 表。
看更多...
我還注意到,當“.”時,JMP 似乎無法正確處理值標籤。是被標記的值之一。 當我有時間時我會將此報告為錯誤
看更多...
Names Default To Here(1);
dt = New Table("Untitled",
Add Rows(4),
New Column("Column 1",
Character,
"Nominal",
Value Labels({"." = "MISSING", "A" = "AAA", "B" = "BBB", "C" = "CCC"}),
Use Value Labels(1),
Set Selected,
Set Values({"A", "B", ".", "C"})
)
);
名稱預設為此處(1); dt = 新表("無標題", 新增行(4), 新列("第1 列", 字元, "標稱", 值標籤({"." = "缺少", "A" = "AAA ", " B" = "BBB", "C" = "CCC"}),使用值標籤(1),設定選定項,設定值({"A", "B", ".", "C "}) ) ) ;
回覆:將文字檔案中的 x 和 y 值匯入 jmp 表並建立晶圓圖再次提醒您使用腳本索引和 jmp 說明。 它們通常是學習此類 JMP 腳本的最佳資源
Names Default To Here(1);
example_str = "\[
WAFER_MAP = {
WAFER_ID = "ABC"
A B C = 123
]\";
example_list = Words(example_str, "\!N");
Show(example_list);
Remove From(example_list, 1); // drop first index. Why it is fine in this case?
// loop over lines until "MAP = {" I'll just use hardcoded index for example
// I'll also save values to variables
// but associative array would be better in this case
wafer_id_line = example_list[1];
Show(wafer_id_line);
wafer_id = Word(2, wafer_id_line, "="); // you might have to remove extra quotes
show(wafer_id);
example_aa = Associative Array();
//adding values to associative array could be done with something like
example_aa["WAFER_ID"] = Word(2, wafer_id_line, "="); // you might have to remove extra quotes
show(example_aa);
回覆:將文字檔案中的 x 和 y 值匯入 jmp 表並建立晶圓圖評分此翻譯: 感謝你的評分 不好 好@jthi讓我知道我錯過了什麼。 我知道我已經很接近了。 您可以分享一個範例程式碼以便我參考嗎? 我還在學習如何彈奏弦樂
回覆:將文字檔案中的 x 和 y 值匯入 jmp 表並建立晶圓圖如果您也想要其他信息,我會改變方法。 由於文件中的資料每行都有新資料(晶圓圖除外),我將使用Words() 並在行更改時進行拆分(您仍然可以使用Words() 生成的列表中的Contains 來查找晶圓圖何時啟動,但它是列表中的索引,而不是字串中的索引)。 然後我會將資訊添加到關聯數組中以使其更容易訪問(這將需要一些循環和更多的 Words() 使用))
回覆:將文字檔案中的 x 和 y 值匯入 jmp 表並建立晶圓圖希望你一切順利@jthi ,!
關於這次討論的真正的快速問題-
我還想導入 jmp 資料表中 txt 檔案中的所有字串,包括標題資訊。 最終的資料表應包含所有字串,並且每個字元應被視為一個單獨的單字。 它應該看起來像這樣。

您建議的邏輯在第 13 行之後不起作用。 任何幫助將非常感激
map_str =
"\[
WAFER_MAP = {
WAFER_ID = ""
BIN G = "Passing"
MAP = {
.....GGG.....
....BGGGG....
...BGGGGGG...
..GGGGGGGGG..
.GGGGGGBBGGG.
GGGGGGGBBGGGB
GGGGGGGGGGGGB
GGGGGGGGGGGGB
.GGGGGGGGGGG.
..GGGGGGGGG..
...GGGGGGG...
....GGGGG....
.....GGG.....
}
}
]\";
l = Words( map_str, "\!N" );
rowc = N Items( l );
colc = N Items( Words( l[1], "" ) );
dt = New Table( "Summary Bins",
Add Rows( rowc * colc ),
New Column( "X coord", Numeric, Ordinal ),
New Column( "Y coord", Numeric, Ordinal ),
New Column( "Bins", Character, Nominal, Label( 1 ) )
);
Try(
For Each( {line, idx}, l,
cur_rows = ((idx - 1) * colc :: (idx * colc - 1)) + 1;
dt[cur_rows, "X coord"] = ((1 :: colc))`;
;
dt[cur_rows, "Y coord"] = (J( 1, colc ) * (idx))`;
dt[cur_rows, "Bins"] = Words( line, "" );
)
);謝謝你的時間!
回覆:將文字檔案中的 x 和 y 值匯入 jmp 表並建立晶圓圖您可以使用 Contains 跳過第一個“MAP = {”或從末尾搜尋(讀取腳本索引...)

回覆:將文字檔案中的 x 和 y 值匯入 jmp 表並建立晶圓圖@jthi
有兩個字串包含“ MAP = {" 下面反白:

我嘗試使用 & 語句不選擇第一個,但它不起作用。
demo_str = Load text file("New wafer map.txt");
a = Contains(demo_str,"MAP = {") & Contains(demo_str,"WAFER_MAP = {") ==0; // get the location of the string "MAP ={"
回覆:將文字檔案中的 x 和 y 值匯入 jmp 表並建立晶圓圖您可以嘗試包含“MAP = {”。 這應該為您提供字串中「MAP = {」的位置,然後將這些知識與 Substr 結合使用來獲得您想要的內容。 請同時檢查腳本索引(可能也可以從腳本索引開啟 JMP 幫助)以了解 Substr(和其他函數)的工作原理。
回覆:將文字檔案中的 x 和 y 值匯入 jmp 表並建立晶圓圖您可以嘗試包含“MAP = {”。 這應該為您提供字串中「MAP = {」的位置,然後將這些知識與 Substr 結合使用來獲得您想要的內容
回覆:將文字檔案中的 x 和 y 值匯入 jmp 表並建立晶圓圖@tx尼爾森,
如果第一行中的模式與 contains 語句匹配,則您的方法有效。 我有幾張晶圓圖,它們的圖案不一樣。 唯一的相似之處是晶圓圖案從文字檔案中的第 21 行開始。 有沒有辦法定義腳本開始讀取的行號? 我附上了晶圓圖文字檔以供參考(在記事本++上查看效果更好)
回覆:將文字檔案中的 x 和 y 值匯入 jmp 表並建立晶圓圖map_str = Substr(
demo_str,
Contains( demo_str, ".X." ),
Length( demo_str ) - Contains( demo_str, ".X." ) -1
);
注意:在腳本索引中尋找 Stbstr() 函數的定義和範例
回覆:將文字檔案中的 x 和 y 值匯入 jmp 表並建立晶圓圖這是很好的解釋@jthi 。
快速提問:
下面的語句將從清單的第二行開始讀取資料。 我不想閱讀包含大括號“}”的最後一行。
如何在腳本中定義結束行
map_str = Substr(demo_str, Contains(demo_str, ".X."));
回覆:將文字檔案中的 x 和 y 值匯入 jmp 表並建立晶圓圖您需要以這樣的方式操作從 Load Text File() 獲得的字串,以便最終獲得僅包含文字檔案的晶圓圖部分的字串。 這不會給出所需的最終字串,但會給出您可以做什麼的想法。 請參閱腳本索引(和 JMP 說明)以了解 Substr 和 Contains 的工作原理。 它還有一個使用單字和包含的選項,這也需要一些修改才能獲得正確的清單。
Names Default To Here(1);
demo_str = "SOMETHING
TEXT
EXAMPLE
MAP = {
.X.
XXX
.X.
}";
map_str = Substr(demo_str, Contains(demo_str, "MAP = {"));
show(map_str);
stop();
demo_list = Words(demo_str, "\!N");
map_start = Contains(demo_list, "MAP = {");
map_list = demo_list[map_start::N Items(demo_list)];
show(map_list);
回覆:將文字檔案中的 x 和 y 值匯入 jmp 表並建立晶圓圖抱歉再次打擾您。 我嘗試了 substr 但程式碼中有一些不正確的地方。 如果可以修改就太好了
map_str = Load Text File();
l = Words( map_str, "\!N" );
rowc = N Items( l );
colc = N Items( Words( l[21], "" ) ); //// edits
dt = New Table( "Untitled",
Add Rows( rowc * colc ),
New Column( "X", Numeric, Continuous ),
New Column( "Y", Numeric, Continuous ),
New Column( "bin", Character, Nominal, Label( 1 ) )
);
For Each( {line, idx}, l,
cur_rows = ((idx - 1) * colc :: (idx * colc - 1)) + 1;
dt[cur_rows, "X"] = ((1 :: colc))`;
dt[cur_rows, "Y"] = (J( 1, colc ) * (idx))`;
dt[cur_rows, "bin"] = substr( line, 1 );
);
回覆:將文字檔案中的 x 和 y 值匯入 jmp 表並建立晶圓圖您應該使用某種方法來僅獲取晶圓圖(如果您只關心它)。 目前您正在使用整個文字檔案。 一些選項是
- 正規表示式
- 帶有包含的子字串
- 單字並在 {} 上拆分
- 單字和行拆分更改並將其與包含合併
- 硬編碼線並根據這些線獲取晶圓圖(通常是非常糟糕的主意)
回覆:將文字檔案中的 x 和 y 值匯入 jmp 表並建立晶圓圖@jthi
只是一個簡單的問題
實際的文字檔案在開始時包含晶圓資訊。 我想儲存第 21 行的資料。 我將jsl修改如下。 它確實按預期讀取。 有什麼建議麼?

map_str = Load Text File();
l = Words( map_str, "\!N" );
rowc = N Items( l );
colc = N Items( Words( l[21], "" ) ); //// edits
dt = New Table( "Untitled",
Add Rows( rowc * colc ),
New Column( "X", Numeric, Continuous ),
New Column( "Y", Numeric, Continuous ),
New Column( "bin", Character, Nominal, Label( 1 ) )
);
For Each( {line, idx}, l,
cur_rows = ((idx - 1) * colc :: (idx * colc - 1)) + 1;
dt[cur_rows, "X"] = ((1 :: colc))`;
dt[cur_rows, "Y"] = (J( 1, colc ) * (idx))`;
dt[cur_rows, "bin"] = Words( line, "" );
);
回覆:將文字檔案中的 x 和 y 值匯入 jmp 表並建立晶圓圖這是一部傑作。 非常感謝! :笑臉:
回覆:將文字檔案中的 x 和 y 值匯入 jmp 表並建立晶圓圖使用更簡單的表
Names Default To Here(1);
// Simple example table
dt = New Table(
"Untitled",
Add Rows(9),
New Column("X", Numeric, "Continuous", Format("Best", 12), Set Values([1, 2, 3, 1, 2, 3, 1, 2, 3])),
New Column("Y", Numeric, "Continuous", Format("Best", 12), Set Values([1, 1, 1, 2, 2, 2, 3, 3, 3])),
New Column("bin", Character, "Nominal", Set Values({".", "X", ".", "X", "X", "X", ".", "X", "."}))
);
//empty string initialization
str = "";
// get unique values for Y
// I will use Associative array instead of Summarize to keep correct format of values
// Summarize would change them to strings
y_uniq = Associative Array(:Y) << get keys;
For Each({cur_y}, y_uniq,
cur_line_rows = Loc(dt[0, "Y"], cur_y); // Loc() with datatable subscripting
line_bins = dt[cur_line_rows, "bin"]; // more datatable subscripting
bin_str = Concat Items(line_bins, "");
str = str || bin_str || "\!N";
);
// remove extra whitespace
str = Trim Whitespace(str);
Write(str);


回覆:將文字檔案中的 x 和 y 值匯入 jmp 表並建立晶圓圖讚賞@jthi
我是 JSL 編碼新手。 能分享一個例子嗎? 僅供參考
回覆:將文字檔案中的 x 和 y 值匯入 jmp 表並建立晶圓圖初始化空字串,按順序循環表Y 值,取得當前y 的行號,使用這些行號取得bin,將這些bin 加到初始化字串(Concat Items() 應該對此有所幫助),並添加行更改並繼續到下一個 Y。 如果需要的話,循環後修剪空格。
回覆:將文字檔案中的 x 和 y 值匯入 jmp 表並建立晶圓圖它的作用就像魅力一樣。 多謝@jthi ,
我正在嘗試將文字檔案中的單字匯入到 jmp 資料表中,然後為 jmp 表中的這些 bin 分配不同的字母,然後使用原始格式轉換回文字文件
map_str =
".....GGG.....
....BGGGG....
...BGGGGGG...
..GGGGGGGGG..
.GGGGGGBBGGG.
GGGGGGGBBGGGB
GGGGGGGGGGGGB
GGGGGGGGGGGGB
.GGGGGGGGGGG.
..GGGGGGGGG..
...GGGGGGG...
....GGGGG....
.....GGG.....";
如何將資料表 X 、 Y 和 bin 轉換回文字檔案格式並保持格式不變。 有什麼建議嗎?
回覆:將文字檔案中的 x 和 y 值匯入 jmp 表並建立晶圓圖我無法分享我使用的程式碼,但這是一個包含一些想法的快速範例
Names Default To Here(1);
// load text file
// parse interesting things
// get map to string
map_str =
".....GGG.....
....BGGGG....
...BGGGGGG...
..GGGGGGGGG..
.GGGGGGBBGGG.
GGGGGGGBBGGGB
GGGGGGGGGGGGB
GGGGGGGGGGGGB
.GGGGGGGGGGG.
..GGGGGGGGG..
...GGGGGGG...
....GGGGG....
.....GGG.....";
l = Words(map_str, "\!N");
rowc = N Items(l);
colc = N Items(Words(l[1], ""));
dt = New Table("Untitled",
Add Rows(rowc * colc),
New Column("X", Numeric, Continuous),
New Column("Y", Numeric, Continuous),
New Column("bin", Character, Nominal, Label(1))
);
For Each({line, idx}, l,
cur_rows = ((idx - 1) * colc::(idx * colc - 1)) + 1;
dt[cur_rows, "X"] = ((1::colc))`;
dt[cur_rows, "Y"] = (J(1, colc) * (idx))`;
dt[cur_rows, "bin"] = Words(line, "");
);
nw = New Window("test",
H List Box(
align("center"),
Text Box(map_str, <<SET font="" name=""></SET>

回覆:將文字檔案中的 x 和 y 值匯入 jmp 表並建立晶圓圖@jthi
我想將附加文字檔案中的模具位置和 jmp 資料表 X 列和 Y 列中的字母儲存起來。 H如何使用JSL將txt檔案當作表格資料處理?

JMP 表:

回覆:將文字檔案中的 x 和 y 值匯入 jmp 表並建立晶圓圖謝謝@jthi
您介意分享代碼以便我參考嗎?
謝謝,
傑克
回覆:將文字檔案中的 x 和 y 值匯入 jmp 表並建立晶圓圖我已經使用 JMP 將幾種不同類型的晶圓圖格式化為基於文字檔案的 XY 座標(和地圖檔案)。 透過“手動”腳本來完成它,我認為這個過程是這樣的:
- 解析文字檔案並獲取重要資訊(Regex、Words 和其他字元函數在這裡很有幫助)
- 行數
- X尺寸、Y尺寸
- Bin 類型(尤其是 null/empty 類型)
- 晶圓圖
- 任何其他資訊(晶圓 ID、類型...)
- 建立新的資料表,您可以將結果收集到其中
- 行數很可能是行數 * 列數
- 您至少需要 X 和 Y 列,如果您對不同的 bin 感興趣,您也需要為其新增列
- 使用 Words(wafermap_txt, "\!N") 循環晶圓圖字串以取得每一行,並根據您要填入的列乘以 xsize/ysize 來建立值。
- 如果您不關心寬度和高度並且可以僅使用 1 / 固定值,則此步驟會容易得多
- 將它們編碼為 JMP 地圖檔案所需的座標也可能是一個好主意,這允許您使用尺寸建立地圖形狀檔案。
- 如果您只對晶圓圖感興趣,則可以省略空箱,但在建立地圖時必須考慮到這一點
回覆:將文字檔案中的 x 和 y 值匯入 jmp 表並建立晶圓圖搜尋 jmp 插件和過去有關晶圓圖的討論。 那裡有很多答案