Computer Chess Club Archives


Search

Terms

Messages

Subject: Re: PGN to FEN

Author: Mike Byrne

Date: 19:41:50 03/06/04

Go up one level in this thread


On March 06, 2004 at 22:28:08, Jeff White wrote:

>I have a file of positions in pgn format, 1154 of them to be exact. Here is an
>example of one:
>
>[Event "Combination Challenge!"]
>[Site "?"]
>[Date "1992.??.??"]
>[Round "?"]
>[White "01"]
>[Black "?"]
>[Result "*"]
>[SetUp "1"]
>[FEN "3rn1k1/p4ppp/1p4b1/2p1Q3/2P1P3/P4P2/1B1qBP1P/1R5K w - - 0 1"]
>[PlyCount "0"]
>[EventDate "1991.??.??"]
>[SourceDate "2002.08.06"]
>
>What I want to do is just have the fen line without everything else. I tried the
>program pgn2fen without success. I don't want to have to edit out everything
>except the fen line with a word processor. Basically I want 1154 fen lines. How
>do I go about doing this? Any help anyone can provide is greatly appreciated.
>Thanks very much.
>
>Regards,
>Jeff


If you have  a text editor like Kedit - this is very simple.  It could take a
minute or 2 using Kedit.

Even without Kedit it very simple- perhaps you use MS Excel? ...copy your pgn
fin Excel file in -- sort the file ---all the lines with "FEN" will then be
grouped together - delete the unncessary lines.  Using your "text to column"
tool, select the quote sign  ["} as the delimiter and ignore (skip) everything
before and after the quotes -  it might take 3-4 minutes in Excel.

Michael




This page took 0 seconds to execute

Last modified: Thu, 15 Apr 21 08:11:13 -0700

Current Computer Chess Club Forums at Talkchess. This site by Sean Mintz.