;;;; Programmer: Kevin M. Rosenberg
;;;; Date Started: Apr 2000
;;;;
-;;;; $Id: classes.lisp,v 1.10 2002/11/04 19:19:04 kevin Exp $
+;;;; $Id: classes.lisp,v 1.11 2002/11/10 22:39:15 kevin Exp $
;;;;
;;;; This file, part of UMLisp, is
;;;; Copyright (c) 2000-2002 by Kevin M. Rosenberg, M.D.
(:ref-fields (sab find-bsab-sab))
(:fields (sab :string) (code :string) (atn :string) (atv :cdata)))
+(defclass usab (umlsclass)
+ ((vcui :type fixnum :initarg :vcui :reader vcui)
+ (rcui :type fixnum :initarg :rcui :reader rcui)
+ (vsab :type string :initarg :vsab :reader vsab)
+ (rsab :type string :initarg :rsab :reader rsab)
+ (son :type string :initarg :son :reader son)
+ (sf :type string :initarg :sf :reader sf)
+ (sver :type string :initarg :sver :reader sver)
+ (mstart :type string :initarg :mstart :reader mstart)
+ (mend :type string :initarg :mend :reader mend)
+ (imeta :type string :initarg :imeta :reader imeta)
+ (rmeta :type string :initarg :rmeta :reader rmeta)
+ (slc :type string :initarg :slc :reader slc)
+ (scc :type string :initarg :scc :reader scc)
+ (srl :type fixnum :initarg :srl :reader srl)
+ (tfr :type fixnum :initarg :tfr :reader tfr)
+ (cfr :type fixnum :initarg :cfr :reader cfr)
+ (cxty :type string :initarg :cxty :reader cxty)
+ (ttyl :type string :initarg :ttyl :reader ttyl)
+ (atnl :type string :initarg :atnl :reader atnl)
+ (lat :type string :initarg :lat :reader lat)
+ (cenc :type string :initarg :cenc :reader cenc)
+ (curver :type string :initarg :curver :reader curver)
+ (sabin :type string :initarg :sabin :reader sabin))
+ (:metaclass hyperobject-class)
+ (:default-initargs :vcui nil :rcui nil :vsab nil :rsab nil :son nil :sf nil
+ :sver nil :mstart nil :mend nil :imeta nil :rmeta nil
+ :slc nil :scc nil :srl nil :tfr nil :cfr nil :cxty nil
+ :ttyl nil :atnl nil :lat nil :cenc nil :curver nil
+ :sabin nil)
+ (:title "Source Abbreviation")
+ (:ref-fields (rsab find-ucon-sab))
+ (:fields (vcui :string fmt-cui) (rcui :string fmt-cui)
+ (vsab :string) (rsab :string) (son :cdata) (sf :string)
+ (sver :string) (mstart :string) (mend :string) (imeta :string)
+ (rmeta :string) (slc :cdata) (scc :cdata) (srl :fixnum)
+ (tfr :commainteger) (cfr :commainteger) (cxty :string)
+ (ttyl :string) (atnl :string) (lat :string) (cenc :string)
+ (curver :string) (sabin :string)))
+
(defclass uso (umlsclass)
((sab :type string :initarg :sab :reader sab)
(code :type string :initarg :code :reader code)
;;;; Programmer: Kevin M. Rosenberg
;;;; Date Started: Apr 2000
;;;;
-;;;; $Id: data-structures.lisp,v 1.3 2002/10/09 23:03:41 kevin Exp $
+;;;; $Id: data-structures.lisp,v 1.4 2002/11/10 22:39:15 kevin Exp $
;;;;
;;;; This file, part of UMLisp, is
;;;; Copyright (c) 2000-2002 by Kevin M. Rosenberg, M.D.
;;; Paths for files
(defvar *umls-path*
- (make-pathname :directory '(:absolute "data" "umls" "2002AC"))
+ (make-pathname :directory '(:absolute "data" "umls" "2002AD"))
"Path for base of UMLS data files")
(defvar *meta-path*
+cl-umlisp (2.0-1) unstable; urgency=low
+
+ * Support UMLS 2002AD
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Fri, 8 Nov 2002 09:40:01 -0700
+
cl-umlisp (1.3.1-1) unstable; urgency=low
* Remove 'load-compiled-op from changelog
;;;; Programmer: Kevin M. Rosenberg
;;;; Date Started: Apr 2000
;;;;
-;;;; $Id: parse-2002.lisp,v 1.4 2002/10/14 09:25:20 kevin Exp $
+;;;; $Id: parse-2002.lisp,v 1.5 2002/11/10 22:39:15 kevin Exp $
;;;;
;;;; This file, part of UMLisp, is
;;;; Copyright (c) 2000-2002 by Kevin M. Rosenberg, M.D.
;;; LEX columns
("EUI" sql-u) ("EUI2" sql-u)
;;; Semantic net columns
- ("UI" sql-u) ("UI2" sql-u) ("UI3" sql-u))
+ ("UI" sql-u) ("UI2" sql-u) ("UI3" sql-u)
+ ;; New fields for 2002AD
+ ("RCUI" sql-u) ("VCUI" sql-u) ("CFR" sql-i) ("TFR" sql-i)
+ )
"SQL data types for each non-string column")
(defparameter +custom-tables+
;; Semantic NET indices
("UI" "SRSTRE1") ("UI2" "SRSTRE1") ("UI3" "SRSTRE1")
("STY_RL" "SRDEF") ("RT" "SRDEF") ("STY_RL" "SRSTR") ("STY_RL2" "SRSTR")
- ("RL" "SRSTR"))
+ ("RL" "SRSTR")
+ ("SRL" "MRSAB") ("RSAB" "MRSAB") ("VSAB" "MRSAB") ("RCUI" "MRSAB")
+ ("VCUI" "MRSAB") ("LAT" "MRSAB"))
"Columns in files to index")
-
(defparameter +custom-index-cols+
nil
#+ignore
;;;; Programmer: Kevin M. Rosenberg
;;;; Date Started: Apr 2000
;;;;
-;;;; $Id: sql-classes.lisp,v 1.7 2002/11/07 23:08:00 kevin Exp $
+;;;; $Id: sql-classes.lisp,v 1.8 2002/11/10 22:39:15 kevin Exp $
;;;;
;;;; This file, part of UMLisp, is
;;;; Copyright (c) 2000-2002 by Kevin M. Rosenberg, M.D.
(nreverse ustys)))
+(defun find-usab-rsab (rsab)
+ "Find usab for rsab"
+ (aif (car (mutex-sql-query
+ (format nil "select VCUI,RCUI,VSAB,RSAB,SON,SF,SVER,MSTART,MEND,IMETA,RMETA,SLC,SCC,SRL,TFR,CFR,CXTY,TTYL,ATNL,LAT,CENC,CURVER,SABIN from MRSAB where RSAB='~A'" rsab)))
+ (multiple-value-bind
+ (vcui rcui vsab rsab son sf sver mstart mend imeta rmeta slc scc srl tfr cfr cxty ttyl atnl lat cenc curver sabin) it
+ (make-instance 'usab :vcui (ensure-integer vcui) :rcui (ensure-integer rcui)
+ :vsab vsab :rsab rsab :son son :sf sf :sver sver :mstart mstart
+ :mend mend :imeta imeta :rmeta rmeta :slc slc :scc scc
+ :srl (ensure-integer srl) :tfr (ensure-integer tfr) :cfr (ensure-integer cfr)
+ :cxty cxty :ttyl ttyl :atnl atnl :lat lat :cenc cenc :curver curver
+ :sabin sabin))))
+
(defun find-cui-max ()
(let ((cui (caar (mutex-sql-query "select max(CUI) from MRCON"))))
(ensure-integer cui)))