uk.sci.weather (UK Weather) (uk.sci.weather) For the discussion of daily weather events, chiefly affecting the UK and adjacent parts of Europe, both past and predicted. The discussion is open to all, but contributions on a practical scientific level are encouraged.

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Old January 27th 06, 10:27 PM posted to uk.sci.weather
external usenet poster
 
First recorded activity by Weather-Banter: Oct 2005
Posts: 446
Default I wonder if someone can help ?

Amongst the old Soviet block synops many report rainfall incorrectly in
the 6**** group. I think there should be a 2 at the end of the group not
a 0. e.g...

28879 119// 82004 11226 21274 39990 40307 57008 69900 77171 8802/ 333 11190=
28909 11999 81703 11179 21212 30115 40224 57007 69900 70232 82032 333 11170=
28952 119// 82005 11184 21210 30044 40251 57009 69970 77173 8802/ 333 11179=

Unfortunately the programme I run when decoding does not recognise the
'0' so I have to trawl through the data and manually change these '0's
to 2's. Can anyone think of a quick way I can change this in one hit? It
would save me so much time. I tend to view the raw data in either
Notepad or Wordpad.

Any quick fixes would be much appreciated.

Thanks
--
Keith (Southend)
http://www.southendweather.net

  #2   Report Post  
Old January 27th 06, 10:59 PM posted to uk.sci.weather
external usenet poster
 
First recorded activity by Weather-Banter: Dec 2004
Posts: 4,411
Default I wonder if someone can help ?


Keith (Southend) wrote:
Amongst the old Soviet block synops many report rainfall incorrectly in
the 6**** group. I think there should be a 2 at the end of the group not
a 0. e.g...

28879 119// 82004 11226 21274 39990 40307 57008 69900 77171 8802/ 333 11190=
28909 11999 81703 11179 21212 30115 40224 57007 69900 70232 82032 333 11170=
28952 119// 82005 11184 21210 30044 40251 57009 69970 77173 8802/ 333 11179=

Unfortunately the programme I run when decoding does not recognise the
'0' so I have to trawl through the data and manually change these '0's
to 2's. Can anyone think of a quick way I can change this in one hit? It
would save me so much time. I tend to view the raw data in either
Notepad or Wordpad.

Any quick fixes would be much appreciated.


In Word: Edit Replace Replace 0= with 2=

I don't know if that will work in other programmes. You can replace
spaces with more than one or vice versa and you can replace stuff with
tabs too. A paragraph or a tab is written in as: ^p or ^t.

If you wanted a column instead of a line across you would just replace
a space or spaces with a ^p

And if you wanted to put the line across into a spread-sheet with the
blocks in different cells you would replace the space(s) with tabs (^t)

I imagine Open Office does something similar but the way it inserts
stuff between spread-sheets and word-processors is different.

  #3   Report Post  
Old January 28th 06, 12:34 AM posted to uk.sci.weather
external usenet poster
 
First recorded activity by Weather-Banter: Oct 2004
Posts: 1,163
Default I wonder if someone can help ?

On 27 Jan 2006 15:59:49 -0800, Weatherlawyer wrote:

Amongst the old Soviet block synops many report rainfall incorrectly
in the 6**** group. I think there should be a 2 at the end of the
group not a 0. e.g...

28879 119// 82004 11226 21274 39990 40307 57008 69900 77171 8802/ 333
11190=

In Word: Edit Replace Replace 0= with 2=


Presumably the = means space? Yes, that will work but a global replace
would begger up any other block ending in 0 like block 39990 above.

Keith, the regex:

s/^6(\d\d\d)0$/6$1\x32/g;

Will do it. I'd bung it in a bit of PERL to read the file, process each
line and write out the result.

The sanity checking to make sure it only changes the expected blocks will
be the hard bit. As it stands it will change *all* blocks that start with
6, end with 0 and have three digits between the 6 and 0.

--
Cheers
Dave. pam is missing e-mail



  #4   Report Post  
Old January 28th 06, 08:29 AM posted to uk.sci.weather
external usenet poster
 
First recorded activity by Weather-Banter: Oct 2005
Posts: 446
Default I wonder if someone can help ?

Weatherlawyer wrote:
Keith (Southend) wrote:
Amongst the old Soviet block synops many report rainfall incorrectly in
the 6**** group. I think there should be a 2 at the end of the group not
a 0. e.g...

28879 119// 82004 11226 21274 39990 40307 57008 69900 77171 8802/ 333 11190=
28909 11999 81703 11179 21212 30115 40224 57007 69900 70232 82032 333 11170=
28952 119// 82005 11184 21210 30044 40251 57009 69970 77173 8802/ 333 11179=

Unfortunately the programme I run when decoding does not recognise the
'0' so I have to trawl through the data and manually change these '0's
to 2's. Can anyone think of a quick way I can change this in one hit? It
would save me so much time. I tend to view the raw data in either
Notepad or Wordpad.

Any quick fixes would be much appreciated.


In Word: Edit Replace Replace 0= with 2=

I don't know if that will work in other programmes. You can replace
spaces with more than one or vice versa and you can replace stuff with
tabs too. A paragraph or a tab is written in as: ^p or ^t.

If you wanted a column instead of a line across you would just replace
a space or spaces with a ^p

And if you wanted to put the line across into a spread-sheet with the
blocks in different cells you would replace the space(s) with tabs (^t)

I imagine Open Office does something similar but the way it inserts
stuff between spread-sheets and word-processors is different.


No that won't work as the 6***0 series is rarely at the end were the '=' is.

Thanks all the same.

--
Keith (Southend)
http://www.southendweather.net
  #5   Report Post  
Old January 28th 06, 08:33 AM posted to uk.sci.weather
external usenet poster
 
First recorded activity by Weather-Banter: Oct 2005
Posts: 446
Default I wonder if someone can help ?

Dave Liquorice wrote:
On 27 Jan 2006 15:59:49 -0800, Weatherlawyer wrote:

Amongst the old Soviet block synops many report rainfall incorrectly
in the 6**** group. I think there should be a 2 at the end of the
group not a 0. e.g...

28879 119// 82004 11226 21274 39990 40307 57008 69900 77171 8802/ 333
11190=

In Word: Edit Replace Replace 0= with 2=


Presumably the = means space? Yes, that will work but a global replace
would begger up any other block ending in 0 like block 39990 above.

Keith, the regex:

s/^6(\d\d\d)0$/6$1\x32/g;

Will do it. I'd bung it in a bit of PERL to read the file, process each
line and write out the result.

The sanity checking to make sure it only changes the expected blocks will
be the hard bit. As it stands it will change *all* blocks that start with
6, end with 0 and have three digits between the 6 and 0.


Dave,

I'm sure this will do the job, even if I can 'find' before I 'change',
as it would be much quicker.
However, I'm not familiar with PERL, what do I need to do for this to
work.? Anything will save me so much time and eyesight ;-)

Thanks

--
Keith (Southend)
http://www.southendweather.net


  #6   Report Post  
Old January 28th 06, 08:41 AM posted to uk.sci.weather
external usenet poster
 
First recorded activity by Weather-Banter: Nov 2004
Posts: 3,253
Default I wonder if someone can help ?

In message , "Keith (Southend)"
writes
Amongst the old Soviet block synops many report rainfall incorrectly in
the 6**** group. I think there should be a 2 at the end of the group
not a 0. e.g...

28879 119// 82004 11226 21274 39990 40307 57008 69900 77171 8802/ 333 11190=
28909 11999 81703 11179 21212 30115 40224 57007 69900 70232 82032 333 11170=
28952 119// 82005 11184 21210 30044 40251 57009 69970 77173 8802/ 333 11179=

Unfortunately the programme I run when decoding does not recognise the
'0' so I have to trawl through the data and manually change these '0's
to 2's. Can anyone think of a quick way I can change this in one hit?
It would save me so much time. I tend to view the raw data in either
Notepad or Wordpad.

Any quick fixes would be much appreciated.

Thanks


Keith,

According to the WMO Manual on Codes, '0' is a valid number in that
group. Although code table 4019 gives specific definitions only for
figures 1-9 there is a note at the bottom of the table which says

"If the duration of the period of reference is not covered by Code Table
4019 or the period does not end at the time of the report tR shall be
coded 0".

This would appear to mean that the group would then give a rainfall
total for an unspecified period, which is not overly helpful.

Incidentally, the full Manual on Codes is available for download from
the WMO website. Go to

www.wmo.ch

then open the scroll box that says "Search by Alphabetical Topics" and
click on "Codes".

Scroll down to the section headed "Manual on Codes" then click on "Vol
1.1 part A". That contains very detailed explanation of all the
alphanumeric code forms. Vol II is also useful as it gives some regional
varriations.

It's quite a tome but very well worth downloading to have on the shelf
for reference.

Norman.
(delete "thisbit" twice to e-mail)
--
Norman Lynagh Weather Consultancy
Chalfont St Giles 85m a.s.l.
England
  #7   Report Post  
Old January 28th 06, 10:14 AM posted to uk.sci.weather
external usenet poster
 
First recorded activity by Weather-Banter: Feb 2005
Posts: 6,777
Default I wonder if someone can help ?


Keith (Southend) wrote:

I have downloaded these now and will have a good looksee. However, it
would still be nice to be able to make those subtle changes because the
programme I use does not pick up any with a '0' at the end.


Could you not just chang the number at the end (the zero) to a
different code? Or a text equivalent? To tell the processor to change
just the end zero Just change zerospace or zeroequalsign (or whatever
immediately follows the zero) into the code you want it to read?

Edit Replace "0=" to "intermittently read" or whatever.

  #8   Report Post  
Old January 28th 06, 10:30 AM posted to uk.sci.weather
external usenet poster
 
First recorded activity by Weather-Banter: Oct 2005
Posts: 446
Default I wonder if someone can help ?

Weatherlawyer wrote:
Keith (Southend) wrote:

I have downloaded these now and will have a good looksee. However, it
would still be nice to be able to make those subtle changes because the
programme I use does not pick up any with a '0' at the end.


Could you not just chang the number at the end (the zero) to a
different code? Or a text equivalent? To tell the processor to change
just the end zero Just change zerospace or zeroequalsign (or whatever
immediately follows the zero) into the code you want it to read?

Edit Replace "0=" to "intermittently read" or whatever.


Unfortunately there isn't a 'common' factor here. It's a shame I can't
use replace 6***0 with 6***2 ignoring the three numbers i the middle,
but in wordpad etc it has to be exact, no wildcards, as far as I know.

--
Keith (Southend)
http://www.southendweather.net
  #9   Report Post  
Old January 28th 06, 11:54 AM posted to uk.sci.weather
external usenet poster
 
First recorded activity by Weather-Banter: Mar 2005
Posts: 632
Default I wonder if someone can help ?


"Keith (Southend)" wrote in message
news:drfkki$1s0$1
Unfortunately there isn't a 'common' factor here. It's a shame I can't
use replace 6***0 with 6***2 ignoring the three numbers i the middle,
but in wordpad etc it has to be exact, no wildcards, as far as I know.


.... as Norman has written, the '0' indicator is perfectly valid, and
seems to be used widely in both the Russian Federation, and the old
Soviet asian republics. Within the same collective, you can find both
the tR=0 and tR= 1 or 2, so they obviously are aware of the distinction.

The only explanation of why they persist in using '0' (when it clearly
is a 12hr precipitation .. and allowed for within the National coding
practices on the WMO site), is that the precipitation is measured at
some time *other* than at the nominal SYNOP time. For example, I could
imagine a situation where snowfall has to be melted out to gain a
rainfall equivalent, but given the desperately low temperatures and
sometimes high snowfall in these regions, the process would have to be
started a couple of hours beforehand to get a figure ready for the
observation. In this case, it would be misleading to indicate that tR=1
or 2, because those code figures imply that the precipitation is for the
6 or 12 hours up to ob time, whereas in this case, it *would* be a 12hr
PPN figure, but not for the nominal period indicated. There may also be
'regional' / historical reasons why PPN is measured at different times,
other than the nominal WMO main SYNOP times.

I emphasise that is a *guess*, but can't come up with a different
answer.

Is it not possible in your routine to simply declare that '0' has the
same meaning as '2' when decoding? I'm not sure if anywhere else in the
world uses this convention, but from memory, I think that '0' has always
indicated 12hr rainfall totals in this particular region.

Martin.


--
FAQ & Glossary for uk.sci.weather at:-
http://homepage.ntlworld.com/booty.weather/uswfaqfr.htm
and
http://booty.org.uk/booty.weather/metindex.htm


  #10   Report Post  
Old January 28th 06, 12:26 PM posted to uk.sci.weather
external usenet poster
 
First recorded activity by Weather-Banter: Jul 2003
Posts: 943
Default I wonder if someone can help ?

Felly sgrifennodd Mike Causer :
You need one of the popular pattern-matching programs, namely Awk, Perl or
Python. It is a trivial operation for them.


If I understand the original question, it's even more trivial in sed.

cat filename | sed 's/0/2/g' newfilename

Just run that on any UNIX system to replace all 0's with 2's, and write
to a new file. Use regular expressions for matching if required (ask again!

Sorry don't know if sed is available for MS.

Adrian
--
Adrian Shaw ais@
Adran Cyfrifiadureg, Prifysgol Cymru, aber.
Aberystwyth, Ceredigion, Cymru ac.
http://users.aber.ac.uk/ais uk


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Someone help with my maths Lawrence Jenkins uk.sci.weather (UK Weather) 39 May 25th 15 01:42 PM
Can Someone Help me out and tell me what happens next? Lawrence Jenkins uk.sci.weather (UK Weather) 26 February 4th 14 08:30 PM
This husbend can't fu ck his wife... can u help him Freedating girl uk.sci.weather (UK Weather) 0 September 27th 11 10:35 PM
Can someone please help me? Victor Fjellman sci.geo.meteorology (Meteorology) 3 January 27th 06 12:02 PM
Can someone explain Rob Bale uk.sci.weather (UK Weather) 5 August 11th 03 02:43 PM


All times are GMT. The time now is 10:20 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 Weather Banter.
The comments are property of their posters.
 

About Us

"It's about Weather"

 

Copyright © 2017