Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
SpreadSheetAsData(Ruby版)の説明
Search
Sponsored
·
SiteGround - Reliable hosting with speed, security, and support you can count on.
→
まりも
September 16, 2024
Programming
0
18
SpreadSheetAsData(Ruby版)の説明
GitHubに上げたライブラリSpreadSheetAsDataの説明です。
https://github.com/HrmsTrsmgs/SpreadsheetAsData
まりも
September 16, 2024
Tweet
Share
More Decks by まりも
See All by まりも
メンタルモデルから見るオブジェクト設計
hrmstrsmgs
0
220
技術的負債
hrmstrsmgs
0
250
よい設計のプログラムを作るには
hrmstrsmgs
0
81
歴史から理解するJavaScript
hrmstrsmgs
0
69
論理的な考え方
hrmstrsmgs
0
64
論理的な話し合いはなぜ必要か
hrmstrsmgs
0
37
腕のある技術者はなぜ
hrmstrsmgs
0
85
疑似乱数の生成
hrmstrsmgs
0
43
構造化プログラミング
hrmstrsmgs
0
160
Other Decks in Programming
See All in Programming
フルサイクルエンジニアリングをAI Agentで全自動化したい 〜構想と現在地〜
kamina_zzz
0
400
AI前提で考えるiOSアプリのモダナイズ設計
yuukiw00w
0
220
CSC307 Lecture 02
javiergs
PRO
1
770
なぜSQLはAIぽく見えるのか/why does SQL look AI like
florets1
0
450
余白を設計しフロントエンド開発を 加速させる
tsukuha
7
2.1k
組織で育むオブザーバビリティ
ryota_hnk
0
170
CSC307 Lecture 06
javiergs
PRO
0
680
dchart: charts from deck markup
ajstarks
3
990
Grafana:建立系統全知視角的捷徑
blueswen
0
330
MDN Web Docs に日本語翻訳でコントリビュート
ohmori_yusuke
0
640
Vibe Coding - AI 驅動的軟體開發
mickyp100
0
170
「ブロックテーマでは再現できない」は本当か?
inc2734
0
730
Featured
See All Featured
16th Malabo Montpellier Forum Presentation
akademiya2063
PRO
0
47
The Art of Delivering Value - GDevCon NA Keynote
reverentgeek
16
1.8k
Leadership Guide Workshop - DevTernity 2021
reverentgeek
1
200
Reality Check: Gamification 10 Years Later
codingconduct
0
2k
Embracing the Ebb and Flow
colly
88
5k
Effective software design: The role of men in debugging patriarchy in IT @ Voxxed Days AMS
baasie
0
220
Technical Leadership for Architectural Decision Making
baasie
1
240
Darren the Foodie - Storyboard
khoart
PRO
2
2.3k
How to optimise 3,500 product descriptions for ecommerce in one day using ChatGPT
katarinadahlin
PRO
0
3.4k
Abbi's Birthday
coloredviolet
1
4.7k
Building Adaptive Systems
keathley
44
2.9k
CoffeeScript is Beautiful & I Never Want to Write Plain JavaScript Again
sstephenson
162
16k
Transcript
SPREADSHEETASDATA (RUBY版) サブタイトル
SPREADSHEETASDATA • 自作ライブラリ • オープンソースで公開 • Excelの読み書き • 理想の設計の研鑽のため •
Ruby版とC#版 • 今日はRuby版の紹介です GitHub.png
よくあるEXCEL操作ライブラリの問題点 Excelのオートメーションの利用 裏でExcelを立ち上げている 重い Excelのバージョンの影響 マクロはもともと手作業の自動化用
よくあるEXCEL操作ライブラリの問題点 APIの設計 Excel VBAの呪縛 20年以上前の設計 使える機能が多すぎる
こんなライブラリが欲しい Excelのデータを利用するライブラリが簡単に書ける 直観的で使いやすいAPI 最近のRDBやXML読み込みライブラリにそん色ない
ファイルオープン WorkBook.open(‘./Book1.xlsx’) do |book| #bookを扱うコードをここに記述 end
セル puts book.Sheet1.A2 #> Jacob
table = book.Sheet1.A1_D7 # 氏名の書き出し table.where(good_language: 'Ruby').each do |student| puts
student.first_name + ' ' + student.last_name end テーブル
table = book.Sheet1.A_D #平均年齢 puts table. all. map{|student| student.age }.
inject(0){|total, age| total += age } / table.all.size テーブル
シート s = book.Sheet1 s2 = book.Sheet2
シート s = book.一覧表
s = book.Sheet1 puts s.A2 #> Jacob puts s['A2'] #>
Jacob puts s[:A2] #> Jacob 一つのことをたくさんのやり方で
puts s.A2 + ' ' + s.B2 #> Jacob Smith
puts s.C2 + s.C3 + s.C4 #> 40 文字列と数字
p s.E1 #>{blank} p s.E1 + ' ' #> ""
p s.E1+ 0 #> 0 空のセル