-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
v. 0.11 - Added rowsastrings and colsasstrings features to csv-floats…
…-in.
- Loading branch information
Jose Henrique Padovani
committed
Sep 19, 2019
1 parent
d412253
commit 5dffc59
Showing
4 changed files
with
1,020 additions
and
29 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,39 +1,50 @@ | ||
;; OMio - 0.1 - OM input/output: designed to make easier to import/export data | ||
;; OMio - 0.11 - OM input/output: designed to make easier to import/export data | ||
;; 14/sept/2019 | ||
|
||
|
||
(defvar omio) | ||
|
||
(defpackage omio) | ||
|
||
(in-package :omio) | ||
|
||
|
||
(mapc 'om::compile&load (list | ||
;(make-pathname :directory (append (pathname-directory *load-pathname*) (list "sources")) :name "xmls" :type "lisp") | ||
(make-pathname :directory (append (pathname-directory *load-pathname*) (list "sources")) :name "omiocsv" :type "lisp") | ||
)) | ||
|
||
|
||
|
||
;; menu/sub-menu structure | ||
;("sub-pack-name" subpacke-lists class-list function-list class-alias-list) | ||
|
||
; (defvar omio) | ||
; | ||
; (defpackage omio) | ||
|
||
(defvar *subpackages-list* nil) | ||
(setf *subpackages-list* | ||
'( ("csv" nil nil (csv-floats-in) nil) | ||
;("csv" nil nil (csv-floats-in csv-floats-in2) nil) | ||
)) | ||
|
||
|
||
(defvar *subpackages-omio-var* nil) | ||
(setf *subpackages-omio-var* | ||
'(("csv" nil nil ( | ||
|
||
csv-floats-in | ||
|
||
|
||
) nil))) | ||
|
||
;-------------------------------------------------- | ||
;filling packages | ||
;-------------------------------------------------- | ||
(om::fill-library *subpackages-omio-var*) | ||
|
||
(om::fill-library *subpackages-list*) | ||
|
||
|
||
(om::set-lib-release 0.1) | ||
(om::set-lib-release 0.11) | ||
|
||
(om::fill-library | ||
'(("csv" nil nil | ||
(om::csv-floats-in) nil) | ||
)) | ||
(print " | ||
;;;----------------- | ||
;;; OMio 0.1 - in/out functions for OpenMusic | ||
;;; | ||
;;; José Henrique Padovani (2019) | ||
;;;=========================================================================== | ||
") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
; OM File Header - Saved 2019/09/14 17:51:18 | ||
; (6.15 :patc (om-make-point 10 260) (om-make-point 50 205) (om-make-point 1390 534) "" 183 0 nil "2019/09/14 17:51:18") | ||
; OM File Header - Saved 2019/09/19 9:13:32 | ||
; (6.15 :patc (om-make-point 10 260) (om-make-point 0 23) (om-make-point 1440 855) "" 183 0 nil "2019/09/19 9:13:32") | ||
; End File Header | ||
(in-package :om)(load-lib-for (quote ("OMio")))(setf *om-current-persistent* (om-load-patch1 "1. csv-floats-in" (quote ((let ((box (om-load-boxcomment "comment" (om-make-point 375 34) (quote "2. Convert it to a list (csv table) of lists (csv rows)") "" (om-make-point 224 183) nil (om-make-color 0 0 0) (om-make-font "Verdana" 12 :family "Verdana" :style (quote (:plain)) :mode (quote nil))))) (when (fboundp (quote set-active)) (set-active box nil)) box) (let ((box (om-load-boxcomment "comment" (om-make-point 375 34) (quote "1. Choose a valid .csv file (must have only floats/integers)") "" (om-make-point 236 63) nil (om-make-color 0 0 0) (om-make-font "Verdana" 12 :family "Verdana" :style (quote (:plain)) :mode (quote nil))))) (when (fboundp (quote set-active)) (set-active box nil)) box) (let ((box (om-load-boxcall (quote genfun) "FILE-CHOOSER" (quote file-chooser) (quote nil) (om-make-point 137 51) nil nil nil nil 1))) (when (fboundp (quote set-active)) (set-active box nil)) box) (let ((box (om-load-boxcall (quote genfun) "CSV-FLOATS-IN" (quote csv-floats-in) (quote ((om-load-inputfun (quote input-funbox) "<n>" "FILENAME" 5))) (om-make-point 132 166) nil nil nil nil 1))) (when (fboundp (quote set-active)) (set-active box nil)) box))) (quote ((2 0 3 0 nil 0))) nil 6.15)) | ||
(in-package :om)(load-lib-for (quote ("OMio")))(setf *om-current-persistent* (om-load-patch1 "1. csv-floats-in" (quote ((let ((box (om-load-boxcomment "comment" (om-make-point 386 85) (quote "You can change the keyword :defaultformat to short-floats if you don't need long floats precision. (see documentation of the function)") "" (om-make-point 167 449) nil (om-make-color 0 0 0) (om-make-font "Verdana" 12 :family "Verdana" :style (quote (:plain)) :mode (quote nil))))) (when (fboundp (quote set-active)) (set-active box nil)) box) (let ((box (om-load-boxcall (quote genfun) "CSV-FLOATS-IN" (quote csv-floats-in) (quote ((om-load-inputfun (quote input-funbox) "<n>" "FILENAME" 5) (om-load-inputfun (quote input-funbox) "<n>" "ROWSASSTRINGS" nil) (om-load-inputfun (quote input-funbox) "<n>" "COLSASSTRINGS" nil) (om-load-inputkeyword (quote input-keyword) "" "defaultformat" (quote :defaultformat) (quote long-float) nil))) (om-make-point 57 450) nil nil nil nil 1))) (when (fboundp (quote set-active)) (set-active box nil)) box) (let ((box (om-load-boxcall (quote bastype) "aux 2" (quote t) (quote nil) (om-make-point 129 297) (om-make-point 48 30) (list 0 4) "(0 4)" nil))) (when (fboundp (quote set-active)) (set-active box nil)) box) (let ((box (om-load-boxcomment "comment" (om-make-point 407 42) (quote "You can specify which rows should be read as strings instead of numbers (the header of the table, for example)") "" (om-make-point 123 216) nil (om-make-color 0 0 0) (om-make-font "Verdana" 12 :family "Verdana" :style (quote (:plain)) :mode (quote nil))))) (when (fboundp (quote set-active)) (set-active box nil)) box) (let ((box (om-load-boxcall (quote bastype) "aux" (quote t) (quote nil) (om-make-point 79 224) (om-make-point 37 30) (list 0) "(0)" nil))) (when (fboundp (quote set-active)) (set-active box nil)) box) (let ((box (om-load-boxcall (quote genfun) "CSV-FLOATS-IN" (quote csv-floats-in) (quote ((om-load-inputfun (quote input-funbox) "<n>" "FILENAME" 5) (om-load-inputfun (quote input-funbox) "<n>" "ROWSASSTRINGS" nil) (om-load-inputfun (quote input-funbox) "<n>" "COLSASSTRINGS" nil))) (om-make-point 57 338) nil nil nil nil 1))) (when (fboundp (quote set-active)) (set-active box nil)) box) (let ((box (om-load-boxcomment "comment" (om-make-point 386 85) (quote "Likewise, you can specify which columns of the table should be read as strings instead of numbers. In this example, the entire first row will be read as a list of strings. From the second row onwards, the first and the fifth columns (nth 0 and 4) will also be read as strings.") "" (om-make-point 188 286) nil (om-make-color 0 0 0) (om-make-font "Verdana" 12 :family "Verdana" :style (quote (:plain)) :mode (quote nil))))) (when (fboundp (quote set-active)) (set-active box nil)) box) (let ((box (om-load-boxcomment "comment" (om-make-point 375 34) (quote "2. Convert it to a list (csv table) of lists (csv rows)") "" (om-make-point 140 119) nil (om-make-color 0 0 0) (om-make-font "Verdana" 12 :family "Verdana" :style (quote (:plain)) :mode (quote nil))))) (when (fboundp (quote set-active)) (set-active box nil)) box) (let ((box (om-load-boxcomment "comment" (om-make-point 375 34) (quote "1. Choose a valid .csv file ") "" (om-make-point 138 34) nil (om-make-color 0 0 0) (om-make-font "Verdana" 12 :family "Verdana" :style (quote (:plain)) :mode (quote nil))))) (when (fboundp (quote set-active)) (set-active box nil)) box) (let ((box (om-load-boxcall (quote genfun) "FILE-CHOOSER" (quote file-chooser) (quote nil) (om-make-point 64 24) nil nil nil nil 1))) (when (fboundp (quote set-active)) (set-active box nil)) box) (let ((box (om-load-boxcall (quote genfun) "CSV-FLOATS-IN" (quote csv-floats-in) (quote ((om-load-inputfun (quote input-funbox) "<n>" "FILENAME" 5))) (om-make-point 60 100) nil nil nil nil 1))) (when (fboundp (quote set-active)) (set-active box nil)) box))) (quote ((4 0 5 1 nil 0) (2 0 5 2 nil 0) (9 0 10 0 nil 0))) nil 6.15)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.