화면 7. Table.cellContent [sink]
원본: Computation Layer 문서(Table (표)) · Try It (원본 화면)
| 화면 번호 | 7 / 17 |
|---|
| 문서 항목 설명 (원문) | cellContentrowIndex: number, columnIndex: number Sets the contents of a cell given the row index and column index of the cell. (Row index 1 is the first row underneath the header.) |
|---|
1. 화면 캡처 (빨간 번호 = 아래 표의 번호)
화면에 적힌 영어 문구(원문):
2. CL이 입력된 곳
코드 안의 회색 줄은 원문 영어 주석이고, 파란 줄은 그 영어 주석의 번역이며, 연분홍 줄은 코드가 하는 일의 설명이다.
| 번호 | 이름 | 종류 | CL 코드 원문, 번역, 설명 |
| 1 | 레이블 없는 표 | 표 | # Sets the content of cell 1 to the area calculated in the graph.
▷ 1번 셀의 내용을 그래프에서 계산한 넓이로 정한다.
cellContent(1,1): "${graph.number("A_{rea}")}"
▶ 표의 1행 1열 셀의 내용(cellContent)은 그래프 graph의 변수 A_{rea}의 값이 들어간 글자 "${graph.number("A_{rea}")}"로 한다.
cellContent(행, 열)은 행 번호와 열 번호로 지정한 셀의 내용을 정한다. ${ }는 글자 안에 변수의 값을 끼워 넣는 표기이고, 그 안의 "A_{rea}"는 number(...)에 넘기는 변수 이름이다.
# Sets the content of cell 2 to the perimeter calculated in the graph.
▷ 2번 셀의 내용을 그래프에서 계산한 둘레로 정한다.
cellContent(1,2): "${graph.number("P_{erimeter}")}"
▶ 표의 1행 2열 셀의 내용(cellContent)은 그래프 graph의 변수 P_{erimeter}의 값이 들어간 글자 "${graph.number("P_{erimeter}")}"로 한다.
${ } 안의 "P_{erimeter}"는 number(...)에 넘기는 변수 이름이다.
|