• CAS
  • |
  • C&EN
  • |
  • Journals
  • |
  • ACS

search site
Advanced Search »
  • Home
  • |
  • About CAS
    • CAS Media Library
    • CAS Quotes
    • Colors of Chemistry
    • 100th Anniversary Celebration
    • Careers at CAS
    • FAQs
    • Directions to CAS
    • Contact Us
  • |
  • Our Expertise
    • CAS Databases
    • Value Added Tools
    • Technical Service and Support
  • |
  • Solutions
    • Researchers
    • IP Professionals
    • Information Professionals
    • Academics
  • |
  • Products & Services
    • SciFinder
    • STN Family of Products
    • Science IP
    • CAS Client Services
    • CAS Document Detective Service
    • CD Products
    • Print Products
  • |
  • Support & Training
    • SciFinder
    • SciFinder Scholar
    • STN
    • STN Express
    • STN AnaVist
    • STN Viewer
    • STN on the Web
    • STN Easy
    • CAS Customer Care
  • |
  • News & Events
    • What's New
    • Press Room
    • News Releases
    • In the News
    • CAS - Science Connections
    • Trade Shows
Home   •   Support  •  STN  •  STNews  •  Articles  •  Using LEN n to extract the first n characters
Power Up: Using "LEN n" to extract only the first n characters from display fields for analysis and searching

Many STN searchers are aware of the benefits of extracting terms from display fields for use in analysis or searching.  But, did you know that you can extract only the first part of the desired terms rather than the whole term?  

The "LENGTH (LEN) n" keyword, used with an extraction command (SELECT, ANALYZE, or TRANSFER), allows you to extract only a specified number (n) of characters or less.  For example, you might use LEN n to extract only the first segment of a patent classification code.

This article shows two methods for taking advantage of LEN n:

  • Using LEN n in command-line extraction and searching
  • Specifying extracted term length with the STN Express Analyze Wizard


SELECT, ANALYZE, and TRANSFER

Three STN commands allow you to extract data from display fields for use in data analysis or as search terms:  

  • SELECT places extracted terms in an E-number table. 
  • ANALYZE places extracted terms in an L-number.
  • TRANSFER extracts terms in an L-number and then searches that L-number. 

SELECT works only with single-database L-numbers, while ANALYZE and TRANSFER work with both single-database and multifile L-number answer sets.  It is also important to note that there are cost differences among the three commands. 

To determine which display fields can be extracted for a particular database, consult the STN Database Summary Sheet or enter HELP EFIELDS at an arrow prompt in the database.


Using LEN n in command-line extraction and searching

To extract only the first n (or fewer) characters of each term, add LEN n to the SELECT, ANALYZE, or TRANSFER command. 

SELECT example:

=> SELECT L2 1-1000 IPC LEN 8
E1 THROUGH E283 ASSIGNED
 
=> D SEL E1-E5

Note that only the first eight characters are selected.

E1 2503 A61K0031/IPC
E2	   1178     A61K0009/IPC
E3	   1126     A61P0009/IPC
E4	   1019     A61K0036/IPC
E5	    396     A61K0038/IPC

ANALYZE example:

=> ANALYZE L2 IPC WITH "C12Q" LEN 8
L4 ANALYZE L2 1- IPC WITH "C12Q" LEN 8 :    4 TERMS
 
=> D
L4 ANALYZE L2 1- IPC WITH "C12Q" LEN 8 :    4 TERMS
TERM #   # OCC  # DOC  % DOC IPC
------ ------- ------ ------ ---------------
     1   13771   1429  18.76 C12Q0001
     2     119     43   0.56 C12Q
     3	  6	 3   0.04 C12Q0015
     4	  2	 1   0.01 C12Q0016
*********  END OF L4 ***

Note: LEN may be used with the WITH or NOT keywords in a SELECT or ANALYZE command.  However, WITH and NOT cannot both be used within the same SELECT or ANALYZE command.  See HELP SELECT or HELP ANALYZE for details.

TRANSFER example:

=> FIL CAPLUS	   
L2	    80 S L1 AND MODEL?
 
=> FIL WPIDS
FILE 'WPIDS' ENTERED AT 09:45:50 ON 
 
=> TRA L2 IPC WITH "C08K" LEN 8
L3     TRANSFER L2 1- IPC WITH "C08K" :    4 TERMS
L4     171375 L3


Specifying extracted term length with the STN Express Analyze Wizard

An advantage of ANALYZE (and TRANSFER) over SELECT is that ANALYZE can be used with multifile answer sets.  This example illustrates the Analyze Wizard with a multifile L-number.

  1. Use STN Express to create a multifile answer set.
  2. Click the Discover! icon button, and select Analyze > Analyze

     Analyze... 

(The Analyze Wizard can alternatively be accessed by clicking the L-number and selecting Analyze)

  1. Select the L-number, and click Next.

    STN Analyze Wizard 

  1. Choose a one or two field analysis, select the field(s) to analyze, and click Options.

    STN Analyze Wizard Select Field 

  1. Select Truncate text to, and specify the number of characters.  Click OK.

    Analyze Wiard Options 

  1. You are returned to the STN Analyze Wizard window.  Click Analyze. 

The analysis includes a chart that displays your results.

   Analysis of WIPO IPC 


Cost differences among SELECT, ANALYZE, and TRANSFER

Although use of the LEN n option does not affect the cost of SELECT, ANALYZE, or TRANSFER, it is important to note that the cost differences for extracting the same data can be significant. 

  • SELECT pricing is based on the exact number of records from which data is extracted, as well as the specific database and fields from which it is extracted.  Many databases do not assess fees for data extraction with SELECT. 
  • The ANALYZE fee is STN-wide and is not based on the database or the fields being extracted.  Three pricing tiers are based on the total number of records from which data is extracted. 
  • TRANSFER has flat fee of $11.65.  However, the search costs can be significant if the target search database has search term fees.

As a general rule, if you are extracting from a very small number of records (from a single database), it is more cost effective to use SELECT.  In most other cases, ANALYZE is more cost effective.

Always use HELP COST to determine the fees prior to using SELECT, ANALYZE, or TRANSFER.

Example comparing SELECT and ANALYZE:

CAplusSM has a $0.36/record fee for SELECT for a text field and $0.09/record for CAS Registry Numbers.

ANALYZE price tiers are:

No. of Records        

Cost

1-1000  $11.65
1001-10,000 $19.55
10,001-50,000  $25.85

The comparative costs for SELECT and ANALYZE are:

No. of Records SELECT CAS Registry Number Cost  SELECT Text Cost   ANALYZE Cost
50   $4.50 $18.00 $11.65
200  $18.00 $72.00                  $11.65
2000   $180.00 $720.00 $19.55
20,000 $1800.00 $7200.00 $25.85


Additional resources

For more information about SELECT, ANALYZE, and TRANSFER, see:

  • Mastering STN Commands
  • ANALYZE and TABULATE for statistical analysis Quick Reference Card (PDF)
  • TRANSFER for crossfile searching Quick Reference Card (PDF)
  • ANALYZE and TABULATE Commands (STNote 17; PDF)
  • STN Express User Guide

See also, the following online HELP messages:

  • HELP SELECT
  • HELP ANALYZE
  • HELP TRANSFER
Updated: 9/25/2008 1:41:31 PM
Home  |  About CAS  |  Our Expertise  |  Solutions  |  Products & Services  |  Support  |  News & Events
Copyright © 2008 American Chemical Society