Extracting a dataframe or table from text in R - r
This is a challenging question, as it might be somehow difficult for the variability that is present. Let's start with the example:
example <- list(c("Birth Centenary of K.S.Stanislavsky.Series:Birth CentenariesCatalog codes:Mi:SU 2710, Sn:SU 2695, Yt:SU 2626, Sg:SU 2797, AFA:SU 2698Variants:Click to see variantsThemes:Actors | Anniversaries and Jubilees | Famous People | MenIssued on:1963-01-15Size:30 x 42 mmColors:Blackish grey greenFormat:StampEmission:CommemorativePerforation:line 12½Printing:RecessPaper:hard thick whiteWatermark:UnwmkFace value:4 Russian kopekPrint run:2,000,000Score:29%\tAccuracy: Very HighBuy Now:2 sale offers from US$ 0.16",
"Birth Centenary of A.S.Serafimovich.Series:Birth CentenariesCatalog codes:Mi:SU 2711, Sn:SU 2696, Yt:SU 2627, Sg:SU 2800, AFA:SU 2699Themes:Anniversaries and Jubilees | Authors | Famous People | Literary People (Poets and Writers) | Literature | MenIssued on:1963-01-19Size:28 x 40 mmFormat:StampEmission:CommemorativePerforation:frame 11½Printing:PhotogravurePaper:ordinaryFace value:4 Russian kopekPrint run:2,500,000Score:26%\tAccuracy: Very HighBuy Now:3 sale offers from US$ 0.11",
"Children in nurserySeries:Soviet ChildrenCatalog codes:Mi:SU 2712, Sn:SU 2697, Yt:SU 2629, Sg:SU 2806, AFA:SU 2700Themes:ChildrenIssued on:1963-01-31Size:42 x 28 mmColors:MulticolorFormat:StampEmission:CommemorativePerforation:comb 11½Printing:PhotogravureFace value:4 Russian kopekPrint run:3,000,000Score:27%\tAccuracy: Very HighDescription:Designer: A. Shmidshtein. Paper: ordinary.Buy Now:2 sale offers from US$ 0.08",
"Children with nurseSeries:Soviet ChildrenCatalog codes:Mi:SU 2713, Sn:SU 2698, Yt:SU 2628, Sg:SU 2807, AFA:SU 2701Themes:ChildrenIssued on:1963-01-31Size:42 x 28 mmFormat:StampEmission:CommemorativePerforation:comb 11½Printing:PhotogravureFace value:4 Russian kopekPrint run:3,000,000Score:25%\tAccuracy: Very HighDescription:Designer: A. Shmidshtein. Paper: ordinary.Buy Now:3 sale offers from US$ 0.08",
"Pioneer campSeries:Soviet ChildrenCatalog codes:Mi:SU 2714, Sn:SU 2699, Yt:SU 2630, Sg:SU 2808, AFA:SU 2702Themes:ChildrenIssued on:1963-01-31Size:42 x 28 mmFormat:StampEmission:CommemorativePerforation:comb 11½Printing:PhotogravureFace value:4 Russian kopekPrint run:3,000,000Score:22%\tAccuracy: Very HighDescription:Designer: A. Shmidshtein. Paper: ordinary.Buy Now:4 sale offers from US$ 0.11",
"Soviet Children.Series:Soviet ChildrenCatalog codes:Mi:SU 2715, Sn:SU 2700, Yt:SU 2631, Sg:SU 2809, AFA:SU 2703Themes:ChildrenIssued on:1963-01-31Size:40 x 28 mmFormat:StampEmission:CommemorativePerforation:comb 11½Printing:PhotogravurePaper:ordinaryFace value:4 Russian kopekPrint run:3,000,000Score:25%\tAccuracy: Very HighBuy Now:2 sale offers from US$ 0.08",
"Dymkov's and Zagorsk toysSeries:Decorative ArtsCatalog codes:Mi:SU 2716, Sn:SU 2701, Yt:SU 2632, Sg:SU 2810, AFA:SU 2704Themes:Art | ToysIssued on:1963-01-31Size:30 x 42 mmFormat:StampEmission:CommemorativePerforation:comb 12 x 12½Printing:Offset lithographyFace value:4 Russian kopekPrint run:3,000,000Score:22%\tAccuracy: Very HighDescription:Designer: E. Komarov. Paper: ordinary.Buy Now:2 sale offers from US$ 0.11",
"Oposhnya potterySeries:Decorative ArtsCatalog codes:Mi:SU 2717, Sn:SU 2702, Yt:SU 2633, Sg:SU 2811, AFA:SU 2705Themes:ArtIssued on:1963-01-31Size:30 x 42 mmFormat:StampEmission:CommemorativePerforation:comb 12 x 12½Printing:Offset lithographyFace value:6 Russian kopekPrint run:3,000,000Score:24%\tAccuracy: Very HighDescription:Designer: E. Komarov. Paper: ordinary.Buy Now:3 sale offers from US$ 0.08",
"Embossing booksSeries:Decorative ArtsCatalog codes:Mi:SU 2718, Sn:SU 2703, Yt:SU 2634, Sg:SU 2812, AFA:SU 2706Themes:Art | BooksIssued on:1963-01-31Size:30 x 42 mmFormat:StampEmission:CommemorativePerforation:comb 12 x 12½Printing:Offset lithographyFace value:10 Russian kopekPrint run:3,000,000Score:27%\tAccuracy: Very HighDescription:Designer: E. Komarov. Paper: ordinary.Buy Now:2 sale offers from US$ 0.44",
"Decorative Arts.Series:Decorative ArtsCatalog codes:Mi:SU 2719, Sn:SU 2704, Yt:SU 2635, Sg:SU 2813, AFA:SU 2707Themes:ArtIssued on:1963-01-31Size:30 x 42 mmFormat:StampEmission:CommemorativePerforation:comb 12 x 12½Printing:Offset lithographyPaper:ordinaryFace value:12 Russian kopekPrint run:3,000,000Score:26%\tAccuracy: Very HighBuy Now:3 sale offers from US$ 0.16"
), NULL, NULL, NULL)
As you can see, it is a list of 4 objects. We can make a vector by unlisting them with unlist(). That's up to you.
The point is that each element comes from a table with his title like this one:
I would like to obtain the same table or dataframe from the text. I observed several points on how the infor is structured:
There are combined words with the difference of the Capital letter, which corresponds to the start of the value of the row and the end of the last word.
Some variables (like Catalog codes and Themes) are formed by different elements.
Occasionally, there might be some rows that can be unpresent in other elements. In the image above, the row Variants appears in that element but not in the rest.
I tried with some functions of the tidyverse environment, but this situation exceeds my capabilities.
It seems like your data stems from webscraping. I'd suggest checking out rvest::html_table() to try and get better formatted results. Otherwise its going to be very messy (i.e. regex).
Very, very messy example code:
untangle <- function(element) {
Title = gsub("^(.*)Series:.*", "\\1", element)
Series = gsub(".*Series:(.*)(Catalog codes:.*)", "\\1", element)
CatalogCodes = gsub(".*Catalog codes:(.*)(Variants|Themes.*)", "\\1", element)
return(data.frame(Title, Series, CatalogCodes, stringsAsFactors=FALSE))
}
for (e in unlist(example)) {
print(untangle(e))
}
Related
Names list and store element in different categories in R
dataframe tidy2: I'd like to convert the part of dataframe that satisfies my specific conditions into a list. For example, for all communities contain "BAYSHIRE", I want to store their facility number, name and licensee as the first element in a list and called this element "BAYSHIRE", for communities contain "EMERITUS" or "BROOKDALE", store their facility number name and licensee as the second element in a list. key = list("BAYSHIRE", c("EMERITUS", "BROOKDALE"), "AGEMARK") big_organization <- list() for (i in 1:length(key)){ org = tidy2 %>% filter(str_detect(Licensee, key[[i]]) | str_detect(Facility_name, key[[i]] )) %>% select(Facility_number, Facility_name, Licensee) big_organization = append(big_organization, or) } big_organization Output for above code: ck.imgur.com/88Ya3.png Expected output: $BAYSHIRE Facility_number Facility_name Licensee 374604274 VISTA DEL LAGO MEMORY CARE DEL DIOS CARE,LLC;BAYSHIRE, LLC 374604267 CLOISTERS OF THE VALLEY, LLC DEL RIO CARE, LLC; BAYSHIRE, LLC 374603778 HERITAGE HILLS HAWKES O-SIDE 1 LLC; BAYSHIRE LLC $EMERITUS, BROOKDALE Facility_number Facility_name Licensee 336413087 BROOKDALE MURRIETA BLC CHANCELLOR-MURRIETA LH LLC 197606301 BROOKDALE MONROVIA BLC GABLES-MONROVIA LP 197606676 BROOKDALE GARDENS OF TARZANA BLC GARDENS-TARZANA, LP 496803339 BROOKDALE PAULIN CREEK BLC LODGE AT PAULIN INC GP, BLC LODGE AT PAULIN LP 306002955 BROOKDALE NOHL RANCH BLC NOHL RANCH LLC 198204758 BROOKDALE OCEAN HOUSE BLC OCEAN HOUSE LP 374601046 BROOKDALE PLACE OF SAN MARCOS BLC-BROOKDALE PLACE OF SAN MARCOS LP 306003639 BROOKDALE BREA BREA BREA LLC; EMERITUS CORPORATION 347003712 BROOKDALE SYLVAN RANCH BREA CITRUS HEIGHTS LLC; EMERITUS CORPORATION 197606945 BROOKDALE CENTRAL WHITTIER BREA WHITTIER LLC; EMERITUS CORPORATION . . . .
Creating cumulative probability of winning in fantasy football league
I'm in a fantasy football league with 12 teams, and through 6 weeks I have gathered all the winning scores: w = c(148.70, 102.56, 170.92, 119.54, 95.62, 145.20, 126.32, 98.78, 78.62, 107.36, 146.46, 108.66, 162.56, 130.38, 103.72, 113.86, 138.04, 120.30, 139.90, 124.20, 115.08, 103.50, 153.00, 109.88, 103.28, 135.12, 115.32, 113.66, 158.12, 135.74, 128.64, 145.14, 105.70, 112.36, 98.60, 109.60) and losing scores: l = c(145.02, 81.86, 140.28, 62.96, 89.72, 112.60, 105.64, 74.42, 70.12, 100.72, 121.82, 95.90, 112.44, 89.88, 100.50, 99.54, 105.14, 107.80, 84.50, 118.38, 68.82, 92.70, 71.30, 86.90, 94.94, 89.44, 105.54, 99.44, 141.14, 98.30, 101.20, 105.90, 97.28, 76.82, 95.62, 66.62) How can I produce a plot that shows the cumulative probability of winning depending on score e.g. approaching 0% below 78.62 (lowest winning) and approaching 100% above 145.02 (highest losing)? For those unfamiliar with fantasy football, it's a head-to-head matchup every week.
Using inbuilt function ecdf() plot(ecdf(w))
Is Guarantee Type attribute required for OTA_HotelResRQ
I have a hotel returning no Guarantee Types such as G, GDPST, etc... This is the first I've seen of this and due to the way the code was written it defaults to the first in an array if the property does not return one. In this case "G". When I perform an OTA_HotelResRQ I get the following error: INVLD PROP REQUIRES A DEPOSIT FOR THIS DATE In this scenario should I omit the Type attribute (as specified here http://webservices.sabre.com/drc/servicedoc/OTA_HotelResLLSRQ_v2.2.0_Design.xml) from the Guarantee node? Here is the HotelPropertyDescriptionLLSRQ response: <?xml version="1.0" encoding="UTF-8"?> <soap-env:Envelope xmlns:soap-env="http://schemas.xmlsoap.org/soap/envelope/"><soap-env:Header><eb:MessageHeader xmlns:eb="http://www.ebxml.org/namespaces/messageHeader" eb:version="1.0" soap-env:mustUnderstand="1"><eb:From><eb:PartyId eb:type="URI">Sabre</eb:PartyId></eb:From><eb:To><eb:PartyId eb:type="URI">REMOVED</eb:PartyId></eb:To><eb:CPAId>REMOVED</eb:CPAId><eb:ConversationId>MyConversationID</eb:ConversationId><eb:Service>HotelPropertyDescriptionLLSRQ</eb:Service><eb:Action>HotelPropertyDescriptionLLSRS</eb:Action><eb:MessageData><eb:MessageId>471353037366360202</eb:MessageId><eb:Timestamp>2016-09-14T01:02:16</eb:Timestamp><eb:RefToMessageId>1422291197</eb:RefToMessageId></eb:MessageData></eb:MessageHeader><wsse:Security xmlns:wsse="http://schemas.xmlsoap.org/ws/2002/12/secext"><wsse:BinarySecurityToken valueType="String" EncodingType="wsse:Base64Binary">Shared/IDL:IceSess\/SessMgr:1\.0.IDL/Common/!ICESMS\/RESC!ICESMSLB\/RES.LB!-3361979970612623474!1331042!0</wsse:BinarySecurityToken></wsse:Security></soap-env:Header><soap-env:Body><HotelPropertyDescriptionRS xmlns="http://webservices.sabre.com/sabreXML/2011/10" xmlns:xs="http://www.w3.org/2011/XMLSchema" xmlns:xsi="http://www.w3.org/2011/XMLSchema-instance" xmlns:stl="http://services.sabre.com/STL/v01" Version="2.0.1"> <stl:ApplicationResults status="Complete"> <stl:Success timeStamp="2016-09-13T20:02:16-05:00"/> </stl:ApplicationResults> <RoomStay> <BasicPropertyInfo ChainCode="UZ" GeoConfidenceLevel="1" HotelCityCode="TSM" HotelCode="0012498" HotelName="HOTEL LA FONDA DE TAOS" Latitude="36.406883" Longitude="-105.57462" NumFloors="3" RPH="001"> <Address> <AddressLine>108 SOUTH PLAZA</AddressLine> <AddressLine>TAOS NM 87571</AddressLine> <CountryCode>US</CountryCode> </Address> <Award Provider="NTM3 CROWN"/> <ContactNumbers> <ContactNumber Fax="1-57-57588508" Phone="1-57-57582211"/> </ContactNumbers> <DirectConnect Ind="true"> <AdditionalData Ind="false"/> <CurrencyConverted Ind="true"/> <DC_AvailParticipant Ind="true"/> <DC_SellParticipant Ind="true"/> <RequestFail Ind="false"/> <UnAvail Ind="false"/> </DirectConnect> <IndexData> <Index CountryState="NM" DistanceDirection="0NW" LocationCode="A" Point="TAOS SKI VALLEY" TransportationCode="O"/> <Index DistanceDirection="16W" LocationCode="C" Point="AXX" TransportationCode="O"/> <Index DistanceDirection="66NE" LocationCode="R" Point="LAM" TransportationCode="O"/> <Index DistanceDirection="73W" LocationCode="R" Point="RTN" TransportationCode="O"/> <Index DistanceDirection="7SE" LocationCode="A" Point="TSM" TransportationCode="O"/> <Index DistanceDirection="72NE" LocationCode="R" Point="SAF" TransportationCode="O"/> </IndexData> <PropertyOptionInfo> <ADA_Accessible Ind="false"/> <AdultsOnly Ind="false"/> <AirportShuttle Ind="false"/> <BeachFront Ind="false"/> <Breakfast Ind="false"/> <BusinessCenter Ind="true"/> <BusinessReady Ind="false"/> <CarRentalCounter>Y</CarRentalCounter> <Conventions Ind="false"/> <Dataport Ind="false"/> <Dining Ind="true"/> <DryClean Ind="false"/> <EcoCertified Ind="false"/> <ExecutiveFloors Ind="false"/> <FamilyPlan Ind="true"/> <FitnessCenter Ind="false"/> <FreeLocalCalls Ind="false"/> <FreeParking Ind="true"/> <FreeShuttle Ind="false"/> <FreeWifiInMeetingRooms Ind="false"/> <FreeWifiInPublicSpaces Ind="false"/> <FreeWifiInRooms Ind="false"/> <FullServiceSpa Ind="false"/> <GameFacilities Ind="true"/> <Golf Ind="false"/> <GovtSafetyFire Ind="false"/> <HighSpeedInternet Ind="true"/> <HypoallergenicRooms Ind="false"/> <IndoorPool Ind="true"/> <IndPetRestriction Ind="false"/> <InRoomCoffeeTea Ind="false"/> <InRoomMiniBar Ind="false"/> <InRoomRefrigerator Ind="false"/> <InRoomSafe Ind="false"/> <InteriorDoorways Ind="false"/> <Jacuzzi Ind="false"/> <KidsFacilities Ind="false"/> <KitchenFacilities Ind="false"/> <MealService Ind="false"/> <MeetingFacilities Ind="true"/> <NoAdultTV Ind="false"/> <NonSmoking Ind="true"/> <OutdoorPool Ind="false"/> <Parking>Y-COMPLIMENTARY</Parking> <Pets Ind="false"/> <Pool Ind="true"/> <PublicTransportationAdjacent Ind="false"/> <Recreation Ind="false"/> <RestrictedRoomAccess Ind="false"/> <RoomService Ind="false"/> <RoomService24Hours Ind="false"/> <RoomsWithBalcony Ind="false"/> <SkiInOutProperty Ind="false"/> <SmokeFree Ind="false"/> <SmokingRoomsAvail Ind="false"/> <Tennis Ind="false"/> <WaterPurificationSystem Ind="false"/> <Wheelchair Ind="false"/> </PropertyOptionInfo> <PropertyTypeInfo> <AllInclusive Ind="false"/> <Apartments Ind="false"/> <BedBreakfast Ind="false"/> <Castle Ind="false"/> <Conventions Ind="false"/> <Economy Ind="false"/> <ExtendedStay Ind="false"/> <Farm Ind="false"/> <First Ind="false"/> <Luxury Ind="false"/> <Moderate Ind="true"/> <Motel Ind="false"/> <Resort Ind="true"/> <Suites Ind="false"/> </PropertyTypeInfo> <SpecialOffers Ind="false"/> <Taxes> <Text>8.18 PCT</Text> <Text>5.00 PCT</Text> </Taxes> <VendorMessages> <Attractions> <Text>PRIMARY CITY -</Text> <Text>SAF - TAOS</Text> <Text>65 MI S</Text> <Text>RIO GRANDE GORGE 12 MI</Text> <Text>TAOS PUEBLO 3 MI</Text> <Text>TAOS SKI VALLEY 18 MI</Text> </Attractions> <Awards> <Text>3 STARS</Text> </Awards> <Cancellation> <Text>-27FEB11 - END -</Text> <Text>CANCEL BY 7 DAYS PRIOR TO 0000 HOURS ON DAY OF ARRIVAL,</Text> <Text>LOCAL HOTEL TIME TO AVOID A CANCELLATION PENALTY</Text> <Text>CANCELLATION POLICY TEXT -</Text> <Text>CANCEL BY 10 00 7 DAYS BEFORE ARRIVAL TO AVOID PENALTY</Text> <Text>OF 1 NIGHT.</Text> </Cancellation> <Deposit> <Text>-27FEB11 - END MON-SUN</Text> <Text>1 NIGHT DEPOSIT REQUIRED FOR ALL RESERVATIONS</Text> <Text>DEPOSIT OF FIRST NIGHT STAY</Text> <Text>ACCEPTED FORMS OF DEPOSIT-</Text> <Text>CREDIT CARD</Text> </Deposit> <Description> <Text>- HOTEL</Text> <Text>RESORT</Text> <Text>YEAR BUILT - 1890 YEAR REMODELED - 2003</Text> <Text>ADDITIONAL PROPERTY DESCRIPTION -</Text> <Text>HISTORICAL BOUTIQUE HOTEL LOCATED ON THE FAMOUS TAOS</Text> <Text>PLAZA. AUTHENTIC SOUTHWESTERN AMBIENCE WITH MODERN</Text> <Text>AMENITIES.</Text> </Description> <Dining> <Text>ADDITIONAL MEAL PLAN DESCRIPTION -</Text> <Text>WALKING TO BENT STREET CAFE/GRAHAMS GRILL/DOC</Text> <Text>MARTINS/ALLEY CANTINA/ESKES BREWPUB/MICHAELS KITCHEN</Text> <Text>RESTAURANT</Text> <Text>RESTAURANT DESCRIPTION -</Text> <Text>WALKING TO BENT STREET CAFE/GRAHAMS GRILL/DOC</Text> <Text>MARTINS/ALLEY CANTINA/ESKES BREWPUB/MICHAELS KITCHEN</Text> </Dining> <Directions> <Text>DIRECTION TO THE PROPERTY FROM AIRPORT SAF -</Text> <Text>65 MI NORTH</Text> </Directions> <Facilities> <Text>ON-SITE FACILITIES -</Text> <Text>GENERAL FACILITIES -</Text> <Text>BANQUET FACILITY CASINO</Text> <Text>COFFEE SHOP ELEVATORS</Text> <Text>INDOOR POOL MEETING ROOM</Text> <Text>NON-SMOKING ROOMS RESTAURANT</Text> <Text>SOLARIUM SPA</Text> <Text>HIGH SPEED WIRELESS</Text> <Text>FREE HIGH SPEED INTERNET CONNECTION</Text> <Text>CHARGEABLE FACILITIES -</Text> <Text>BUSINESS CENTER</Text> <Text>PARKING FACILITIES -</Text> <Text>FREE PARKING</Text> <Text>PUBLIC AREA FACILITIES -</Text> <Text>HIGH SPEED INTERNET ACCESS</Text> <Text>ADDITIONAL ONSITE FACILITIES -</Text> <Text>120 AC 120 DC 24-HOUR FRONT DESK 24-HOUR SECURITY 3</Text> <Text>BEDROOM SUITE ACCESSIBLE PARKING ACCOMMODATIONS WITH</Text> <Text>BALCONY ADJOINING ROOMS ADJOINING ROOMS ADJOINING</Text> <Text>ROOMS OR SUITES AIR CONDITIONED GUEST ROOMS AIR</Text> <Text>CONDITIONING AIRPORT - ALBUQUERQUE SUNPORT 140 MILES</Text> <Text>AIRPORT SHUTTLE - 50.0 ALARM CLOCK ALL NEWS CHANNEL</Text> <Text>ALL PETS - PETS NOT ALLOWED ALL PUBLIC AREAS</Text> <Text>NON-SMOKING ALL ROOMS NON-SMOKING AMERICANS WITH</Text> <Text>DISABILITIES ACT ADA COMPLIANCE ANIMAL WATCHING</Text> <Text>ANTIQUE SHOPPING ARCHEOLOGICAL ARCHERY AUDIO VISUAL</Text> <Text>EQUIPMENT AV EQUIP AVAILABLE SUITES AWAY FROM THE</Text> <Text>ELEVATOR BACK OF BUILDING BACKGROUND MUSIC BAGGAGE</Text> <Text>HOLD BALCONY/LANAI/TERRACE BASKETBALL COURT BATHROOM</Text> <Text>AMENITIES BATHROOM VANITY IN GUEST ROOMS FOR DISABLED</Text> <Text>PERSON HEIGHT BATHTUB BATHTUB/SHOWER COMBINATION BED</Text> <Text>TYPES OF WHEELCHAIR ACCESSIBLE ROOMS BEDROOM</Text> <Text>WHEELCHAIR ACCESS BICYCLE BICYCLE RENTALS BIKE TRAIL</Text> <Text>BILINGUAL STAFF BIRD WATCHING BLACKBOARD BLACKBOARD</Text> <Text>WITH ERASER CHALK BOARDING PASS PRINT-OUT AVAILABLE</Text> <Text>BOATING BOOKSTORE BOTTLED WATER BOUTIQUE BRIDGE</Text> <Text>BUS BUS PARKING BUSINESS LOCATION CABLE TELEVISION</Text> <Text>CALLING CARD CALLS CALLING CARD CALLS CAMPING</Text> <Text>CANOEING CAR CARDIOVASCULAR EXERCISE CATERED</Text> <Text>BREAKFAST CATERED DINNER CATERED LUNCH CATERING</Text> <Text>CATHEDRAL CEILING FAN CEMETERY CERTIFIED WEDDING</Text> <Text>PLANNER CHAIR PROVIDED WITH DESK CHARM HOTEL</Text> <Text>CHILDREN NOT ALLOWED</Text> </Facilities> <Guarantee> <Text>-27FEB11 - END MON-SUN</Text> <Text>SEE DEPOSIT POLICY</Text> <Text>ACCEPTED FORMS OF GUARANTEE-</Text> <Text>CREDIT CARD</Text> <Text>ACCEPTED FORMS OF PAYMENT-</Text> <Text>CREDIT CARD</Text> </Guarantee> <Location> <Text>PRIMARY PROPERTY LOCATION - CITY</Text> <Text>SAF AIRPORT 65 MI N</Text> <Text>RESORT</Text> </Location> <MiscServices> <Text>EMAIL - INFO LAFONDATAOS.COM</Text> <Text>TAXES AND SURCHARGES -</Text> <Text>TAX- 8.18 PCT</Text> <Text>LODGING TAX- 5.00 PCT</Text> <Text>ADDITIONAL CURRENCY AND TAX INFORMATION -</Text> <Text>8.1875 PCT VAT AND 5 PCT LODGERS TAX EXCLUDED</Text> <Text>-27FEB11 - END MON-SUN</Text> <Text>MIN STAY - 1</Text> </MiscServices> <Policies> <Text>EXTRA CHILD - 0.00 USD ROLLAWAY FOR CHILD - 0.00 USD</Text> <Text>CHILDREN STAY FREE -</Text> <Text>CHILDREN WELCOME - NO CHILDREN ALLOWED UNDER AGE 8</Text> <Text>NO PETS ALLOWED -</Text> <Text>ALL PETS - PETS NOT ALLOWED</Text> <Text>PROPERTY OFFERS COMMISSION - RATE OF COMMISSION</Text> <Text>10 PCT</Text> <Text>ADDITIONAL COMMISSION PROGRAMS INFORMATION -</Text> <Text>10 PCT</Text> </Policies> <Recreation> <Text>ON-SITE RECREATION -</Text> <Text>BICYCLING WATER SPORTS</Text> </Recreation> <Rooms> <Text>ROOM AMENITIES FOR ALL ROOMS -</Text> <Text>ROOM AMENITIES -</Text> <Text>AIR CONDITIONING / AM/FM ALARM CLOCK / BATH TUB /</Text> <Text>BATHROOM AMENITIES / CABLE/SATELLITE TV / DIRECT DIAL</Text> <Text>TELEPHONE / FREE LOCAL TELEPHONE CALLS / HAIRDRYER /</Text> <Text>IRON/IRONING BOARD / NO SMOKING ROOM / PRIVATE BATH OR</Text> <Text>SHOWER / RADIO / SHOWER / SMOKE DETECTOR / TELEPHONE/SAFE/</Text> <Text>TELEVISION</Text> <Text>TECHNOLOGY -</Text> <Text>DATAPORT / HIGH SPEED INTERNET ACCESS / VOICE MAIL</Text> <Text>S1K-</Text> <Text>MAX OCCUPANCY - 4</Text> <Text>MAX NBR OF ROLLAWAYS - 0</Text> <Text>ROOM DESCRIPTION -</Text> <Text>NEWLY AND RICHLY REMODELED/ DELUXE TWO ROOM SUITE WITH</Text> <Text>1 KING BED. NEWLY AND RICHLY REMODELED/ DELUXE TWO ROOM</Text> <Text>SUITE WITH 1 KING BED/ SOME WITH SLEEPER SOFA/ MOST</Text> <Text>WITH GAS FIREPLACE/ REFRIGERATOR/ WET BAR/ LUXURIOUS</Text> <Text>LINENS AND HEADBOARD/ A/C CEILING FAN/ ARMOIRE WITH</Text> <Text>COLOR CABLE TV/ DSL CONNECTIVITY/ TELEPHONE WITH VOICE</Text> <Text>MAIL/ ALARM CLOCK/ RADIO/ SMOKE DETECTOR/ HAND-TILED</Text> <Text>BATHROOM WITH TUB AND SHOWER/ BATHROOM AMENITIES/</Text> <Text>IRON/BOARD/ AND HAIRDRYER. 120AC/ 120DC. DAILY MAID</Text> <Text>SERVICE/ FREE PARKING AND ADMITTANCE TO DH LAWRENCE</Text> <Text>FORBIDDEN ART COLLECTION. ALL ROOMS ARE NON-SMOKING.</Text> <Text>PHR -</Text> <Text>MAX OCCUPANCY - 4</Text> <Text>MAX NBR OF ROLLAWAYS - 0</Text> <Text>ROOM DESCRIPTION -</Text> <Text>UNIQUE/ LUXURIOUS 1200 SQ. FT. PLAZA PENTHOUSE/ ONE</Text> <Text>BEDROOM WITH KING BED/ QUEEN SLEEPER SOFA. UNIQUE/</Text> <Text>LUXURIOUS 1200 SQ. FT. PLAZA PENTHOUSE/ ONE BEDROOM</Text> <Text>WITH KING BED/ QUEEN SLEEPER SOFA/ HAND-TILED FULL</Text> <Text>BATH/ LAUNDRY/ FULLY EQUIPPED KITCHEN/ DINING ROOM/</Text> <Text>SUNKEN LIVING ROOM WITH GAS KIVA FIREPLACE/ OUTDOOR</Text> <Text>DECKL/ COLOR CABLE TV/ DESK TOP COMPUTER/ DSL</Text> <Text>CONNECTIVITY/ CEILING FANS/ TELEPHONE WITH VOICE MAIL/</Text> <Text>ALARM CLOCK/ RADIO/ BATH AMENITIES/ HAIR DRYER/ IRON</Text> <Text>AND IRONING BOARD/ DAILY MAID SERVICE/ FREE PARKING AND</Text> <Text>ADMITTANCE TO DH LAWRENCE FORBIDDEN ART COLLECTION.</Text> <Text>TWO/ THREE/ AND FOUR BEDROOM CAPABILITY. CALL FOR</Text> <Text>PRICES AND AVAILABILITY. THIS HOTEL IS A NON-SMOKING</Text> <Text>PROPERTY AND CANNOT ACCOMMODATE PETS. THIS SUITE IS</Text> <Text>NON-SMOKING.</Text> <Text>A1Q -</Text> <Text>MAX OCCUPANCY -</Text> </Rooms> <Safety> <Text>PROPERTY SAFETY AND SECURITY -</Text> <Text>SECURITY AVAILABLE 24 HOURS</Text> <Text>24-HOUR SECURITY</Text> </Safety> <Services> <Text>ON-SITE GENERAL SERVICES -</Text> <Text>BAGGAGE HOLD BICYCLE RENTAL</Text> <Text>FRONT DESK 24 HRS MULTILINGUAL STAFF</Text> <Text>SAFE DEPOSIT BOX WAKE-UP CALLS</Text> <Text>ON-SITE CHARGEABLE SERVICES -</Text> <Text>CAR RENTAL</Text> <Text>BUSINESS SERVICES -</Text> <Text>BUSINESS CENTER</Text> </Services> <Transportation> <Text>TRANSPORTATION FROM PRIMARY AIRPORT TO PROPERTY -</Text> <Text>RENTAL CAR</Text> <Text>TRANSPORTATION FROM CITY CENTER TO PROPERTY -</Text> <Text>RENTAL CAR</Text> </Transportation> </VendorMessages> </BasicPropertyInfo> <Guarantee> <DepositsAccepted> <PaymentCard Code="AX" Type="AMERICAN EXPRESS"/> <PaymentCard Code="CA" Type="MASTERCARD"/> <PaymentCard Code="DS" Type="DISCOVER CARD"/> <PaymentCard Code="VI" Type="VISA"/> </DepositsAccepted> <GuaranteesAccepted> <PaymentCard Code="AX" Type="AMERICAN EXPRESS"/> <PaymentCard Code="CA" Type="MASTERCARD"/> <PaymentCard Code="DS" Type="DISCOVER CARD"/> <PaymentCard Code="VI" Type="VISA"/> </GuaranteesAccepted> </Guarantee> <RoomRates> <RoomRate DirectConnect="false" GuaranteeSurchargeRequired="D" GuaranteedRateProgram="false" HRD_RequiredForSell="false" IATA_CharacteristicIdentification="N1QRAC" IATA_ProductIdentification="PUBLISHED RATE" LowInventoryThreshold="false" RPH="001" RateChangeInd="false" RateConversionInd="false" SpecialOffer="false"> <AdditionalInfo> <CancelPolicy Numeric="03" Option="D"/> <Commission NonCommission="false">10.00 PERCENT COMMISSION</Commission> <Text>STANDARD QUEEN</Text> </AdditionalInfo> <Rates> <Rate Amount="159.00" ChangeIndicator="false" CurrencyCode="USD" HRD_RequiredForSell="false" PackageIndicator="false" RateConversionInd="false" ReturnOfRateInd="false" RoomOnRequest="false"> <AdditionalGuestAmounts> <AdditionalGuestAmount MaxExtraPersonsAllowed="0" NumAdults="0" NumCribs="0"> <Charges AdultRollAway="10.00" Crib="0.00" ExtraPerson="10.00"/> </AdditionalGuestAmount> </AdditionalGuestAmounts> <HotelTotalPricing Amount="359.94"> <Disclaimer>INCLUDES TAXES AND SURCHARGES</Disclaimer> <TotalTaxes Amount="41.94"/> </HotelTotalPricing> </Rate> </Rates> </RoomRate> <RoomRate DirectConnect="false" GuaranteeSurchargeRequired="D" GuaranteedRateProgram="false" HRD_RequiredForSell="false" IATA_CharacteristicIdentification="N1KRAC" IATA_ProductIdentification="PUBLISHED RATE" LowInventoryThreshold="false" RPH="002" RateChangeInd="false" RateConversionInd="false" SpecialOffer="false"> <AdditionalInfo> <CancelPolicy Numeric="03" Option="D"/> <Commission NonCommission="false">10.00 PERCENT COMMISSION</Commission> <Text>STANDARD KING</Text> </AdditionalInfo> <Rates> <Rate Amount="169.00" ChangeIndicator="false" CurrencyCode="USD" HRD_RequiredForSell="false" PackageIndicator="false" RateConversionInd="false" ReturnOfRateInd="false" RoomOnRequest="false"> <AdditionalGuestAmounts> <AdditionalGuestAmount MaxExtraPersonsAllowed="0" NumAdults="0" NumCribs="0"> <Charges AdultRollAway="10.00" Crib="0.00" ExtraPerson="10.00"/> </AdditionalGuestAmount> </AdditionalGuestAmounts> <HotelTotalPricing Amount="382.58"> <Disclaimer>INCLUDES TAXES AND SURCHARGES</Disclaimer> <TotalTaxes Amount="44.58"/> </HotelTotalPricing> </Rate> </Rates> </RoomRate> <RoomRate DirectConnect="false" GuaranteeSurchargeRequired="D" GuaranteedRateProgram="false" HRD_RequiredForSell="false" IATA_CharacteristicIdentification="S1KRAC" IATA_ProductIdentification="PUBLISHED RATE" LowInventoryThreshold="false" RPH="003" RateChangeInd="false" RateConversionInd="false" SpecialOffer="false"> <AdditionalInfo> <CancelPolicy Numeric="03" Option="D"/> <Commission NonCommission="false">10.00 PERCENT COMMISSION</Commission> <Text>KING SUITE</Text> </AdditionalInfo> <Rates> <Rate Amount="199.00" ChangeIndicator="false" CurrencyCode="USD" HRD_RequiredForSell="false" PackageIndicator="false" RateConversionInd="false" ReturnOfRateInd="false" RoomOnRequest="false"> <AdditionalGuestAmounts> <AdditionalGuestAmount MaxExtraPersonsAllowed="0" NumAdults="0" NumCribs="0"> <Charges AdultRollAway="10.00" Crib="0.00" ExtraPerson="10.00"/> </AdditionalGuestAmount> </AdditionalGuestAmounts> <HotelTotalPricing Amount="450.48"> <Disclaimer>INCLUDES TAXES AND SURCHARGES</Disclaimer> <TotalTaxes Amount="52.48"/> </HotelTotalPricing> </Rate> </Rates> </RoomRate> <RoomRate DirectConnect="false" GuaranteeSurchargeRequired="D" GuaranteedRateProgram="false" HRD_RequiredForSell="false" IATA_CharacteristicIdentification="APTRAC" IATA_ProductIdentification="PUBLISHED RATE" LowInventoryThreshold="false" RPH="004" RateChangeInd="false" RateConversionInd="false" SpecialOffer="false"> <AdditionalInfo> <CancelPolicy Numeric="03" Option="D"/> <Commission NonCommission="false">10.00 PERCENT COMMISSION</Commission> <Text>PLAZA PENTHOUSE</Text> </AdditionalInfo> <Rates> <Rate Amount="499.00" ChangeIndicator="false" CurrencyCode="USD" HRD_RequiredForSell="false" PackageIndicator="false" RateConversionInd="false" ReturnOfRateInd="false" RoomOnRequest="false"> <AdditionalGuestAmounts> <AdditionalGuestAmount MaxExtraPersonsAllowed="0" NumAdults="0" NumCribs="0"> <Charges AdultRollAway="10.00" Crib="0.00" ExtraPerson="10.00"/> </AdditionalGuestAmount> </AdditionalGuestAmounts> <HotelTotalPricing Amount="1129.62"> <Disclaimer>INCLUDES TAXES AND SURCHARGES</Disclaimer> <TotalTaxes Amount="131.62"/> </HotelTotalPricing> </Rate> </Rates> </RoomRate> </RoomRates> <TimeSpan Duration="0005" End="2016-10-16" Start="2016-10-14"/> </RoomStay> </HotelPropertyDescriptionRS></soap-env:Body></soap-env:Envelope> REQUEST: <?xml version="1.0" encoding="UTF-8"?> <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> <soapenv:Header> <MessageHeader xmlns="http://www.ebxml.org/namespaces/messageHeader"> <From> <PartyId type="urn:x12.org:IO5:01"><!-- APP SOURCE REMOVED BY OP --></PartyId> </From> <To> <PartyId type="urn:x12.org:IO5:01">Sabre</PartyId> </To> <CPAId><!-- IPCC REMOVED BY OP --></CPAId> <ConversationId>MyConversationID</ConversationId> <Service type="sabreXML">HotelPropertyDescriptionLLSRQ</Service> <Action>HotelPropertyDescriptionLLSRQ</Action> <MessageData> <MessageId>1422291197</MessageId> <Timestamp>2015-01-26T09:53:17-07:00</Timestamp> <TimeToLive>2015-01-26T10:53:17-07:00</TimeToLive> </MessageData> </MessageHeader> <wsse:Security xmlns:wsse="http://schemas.xmlsoap.org/ws/2002/12/secext" xmlns:wsu="http://schemas.xmlsoap.org/ws/2002/12/utility"> <!-- TOKEN REMOVED BY OP --> </wsse:Security> </soapenv:Header> <soapenv:Body> <HotelPropertyDescriptionRQ xmlns="http://webservices.sabre.com/sabreXML/2011/10" xmlns:xs="http://www.w3.org/2001/XMLSchema" Version="2.0.1"> <AvailRequestSegment> <GuestCounts Count="2" /> <HotelSearchCriteria> <Criterion> <HotelRef HotelCode="0012498" /> </Criterion> </HotelSearchCriteria> <TimeSpan Start="10-14" End="10-16" /> </AvailRequestSegment> </HotelPropertyDescriptionRQ> </soapenv:Body> </soapenv:Envelope> Edit: added request, per user request. Items I removed for security have been indicated with comments.
It is strange indeed not having that returned as usual. The answer to your question is: No. Actually that room rate requires a deposit not a guarantee, and it is safe to say that most hotels require one of the 2, so not sending that is probably not a good idea. In this case, you can use GDPST as deposit, since it says that it accepts credit cards, although that is in free text. Now, as you can see in the first rate returned, inside the RoomRate element, you have: GuaranteeSurchargeRequired="D". The values for that attribute are D for Deposit and G for guarantee. I'm not sure if there's something for when there is no guarantee needed, haven't seen any, but it is likely a different element or the element is not returned. In order to know the values for guarantee you can use in the OTA_HotelRes, I recommend you to check the following format finder link: https://formatfinder.sabre.com/Content/Hotels/FourEasyStepstoSellaHotel/0HSellHotel.aspx?ItemID=597F73406BFE49EFB5DF100C096ABFB0
What does it mean counts plot in self organizing maps
I'm using the som function from kohonen package and I'm using this tutorial as a guide. som_model <- som(t(data_train_matrix), grid=som_grid, rlen=1, alpha=c(0.05,0.01), keep.data = TRUE, n.hood= "circular") plot(som_model, type="count") I have a data of 31×1400 but when I'm trying to read the counts plot, it doesn't match the same quantity of samples (31). The plot I got gives me around 100 samples. this is an example of my data structure(c(-8691, 96233, 94318, 19206, 139453, 135652, 47782, 56190, -63139, 161452, 83268, 194879, -4112, 193153, -55742, 168244, -26043, 171304, 67181, -52147, -45487, 77098, 79648, 123380, -52991, 113980, -35812, 161776, -26874, 125046, 89662, 94537, 68053, 59601, 87972, 8844, 82108, 85343, 145252, 130751, 66224, 32792, 101576, 174156, 37090, 102740, 101521, 154264, 28431, 81740, 113085, 104153, 6385, 95860, 67247, 58344, 106147, 225375, -714, 212145, 51164, 24108, 33896, 128937, 182192, 5715, 94954, 198818, 127890, 272457, -45888, 96562, 15617, 22385, 102185, 154694, 93797, 55638, 118959, 184010, 6310, 54728, 141369, 209807, 140799, 100809, 93704, 198260, 264015, 271577, 90354, 125713, 112490, 103888, 186512, 178664, 30646, 100788, 194517, 197307, -3709, 111675, 175022, 186898, 242656, 107932, 269935, 110129, 38492, 88179, 35392, 81003, 118482, 124713, 124830, 78896, 79962, 154348, 181855, 8146, 90599, 115869, 58740, 119922, 12046, 216180, 24770, 329719, 96091, 239658, 119638, 96020, 120758, 144941, 170427, 26691, 112377, 246679, 170131, 314849, 97399, 194975, 60680, 287463, 85241, 145845, 31902, 93297, 305020, 261229, 176675, 146127, 306958, 62111, 101310, 113621, 208697, 73762, 354256, 104883, 202739, 108740, 287507, 106152, 532421, 115689, 643646, 143442, 1026203, 130904, 1951723, 83570, 5818682, 289423, 5864851, 49296, 2369016, 184566, 1184562, 188584, 635480, 88563, 577216, 144760, 454805, 139133, 510350, 40305, 366688, 55486, 258099, 74080, 281519, 162968, 218759, 334500, 353090, 263008, 210560, 445832, 378725, 497266, 298151, 469138, 248365, 381608, 219821, 393548, 116469, 396907, 320685, 429351, 164311, 397822, 270935, 565860, 245619, 435443, 214331, 417268, 268967, 459714, 419833, 348551, 314194, 480522, 183062, 274876, 295398, 470877, 350616, 425871, 642579, 670075, 395643, 679445, 333423, 524843, 207011, 488471, 426073, 263541, 328925, 485258, 419273, 493798, 325854, 505041, 317356, 394418, 254990, 432610, 254212, 459642, 311613, 429672, 340076, 478631, 393919, 415449, 335445, 499644, 310914, 479802, 229937, 317058, 321625, 349939, 410056, 450019, 389055, 544372, 382828, 465619, 441888, 522416, 321660, 562040, 390768, 427916, 356081, 477152, 481436, 609419, 589189, 710624, 1167121, 1884282, 687543, 949401, 613100, 834546, 425695, 613319, 444637, 624192, 684646, 771698, 726366, 813694, 616384, 756803, 483736, 707427, 517319, 761253, 617534, 785160, 765434, 892135, 1057392, 1144724, 902210, 1114782, 1027470, 1488406, 1794285, 3202191, 1680875, 2378078, 1384652, 1942915, 1940959, 2753094, 8178326, 9296747, 17334234, 18341903, 4077766, 4757832, 12437987, 13770176, 5388983, 6043089, 3557519, 4344363, 3462297, 4193800, 3002130, 3751664, 2889390, 3596128, 2990671, 4052441, 4551441, 7645868, 6055792, 8720274, 11204851, 14342229, 13297134, 17421005, 16032135, 22046214, 33034409, 41895354, 134659124, 309713419, 54318759, 138429326, 21521670, 32507615, 31364480, 51975213, 41972208, 70888295, 96423383, 193962950, 127239777, 183865572, 184485432, 362581277, 266284997, 372142920, 254797938, 379524966, 168531540, 217593817, 109955151, 132909067, 45946711, 52766776, 39059161, 46851181, 36854510, 44138904, 42208748, 51775529, 30842738, 38044295, 34739365, 62307643, 35222394, 263589982, 19288663, 53574604, 22473059, 32180156, 15377680, 39229960, 14883020, 37024731, 26775128, 38438456, 31174328, 37159679, 20374102, 24638170, 18843009, 23709900, 16290335, 22019997, 13866224, 21410739, 13409806, 19807146, 12580394, 19423477, 12605523, 20175243, 11286325, 15895629, 12624149, 20150895, 15564663, 23173356, 13344234, 19144941, 16147475, 25059434, 16165655, 22543911, 17719126, 26056352, 25241362, 33870246, 20346030, 25373366, 27599769, 34874263, 19750731, 25488861, 17456089, 26803417, 21655991, 29032569, 18525780, 28589676, 28986493, 54330313, 30702160, 62741684, 36217696, 66746224, 37179427, 70384105, 32845869, 54067819, 40466477, 60334993, 47169915, 71194010, 64983410, 94329526, 107713258, 163970090, 205975485, 422860074, 727019292, 1894177881, 1536778649, 2595541011, 1325315247, 1724342395, 623772789, 933707256, 520787992, 763760597, 484959955, 762351348, 544836917, 814960223, 557751071, 825802985, 484106551, 727516034, 320419472, 473245904, 215986703, 319460038, 176355114, 258972369, 147044357, 203777597, 93349619, 132506190, 89329707, 120091964, 56028958, 73913976, 39160835, 57805430, 31597040, 45502763, 24996502, 38369765, 23164619, 34974560, 23446564, 36260730, 24240365, 37462383, 24380634, 38464790, 23825674, 38232189, 24261678, 40822263, 22545025, 37662136, 25969748, 41828554, 25342961, 41373278, 28190579, 51622837, 40721443, 89715709, 33899480, 63713905, 33879100, 82571628, 33194622, 63495601, 40899580, 83115054, 52391035, 119897472, 43331860, 85516401, 40972806, 111409364, 45229140, 86017237, 60769699, 114219430, 76387165, 153804973, 100612861, 166584932, 119025540, 209322137, 125258469, 215257202, 126370047, 181489720, 114200659, 190602759, 98391103, 165094932, 82887335, 170246121, 62767360, 159226407, 53772778, 144576214, 56504793, 178803162, 54720435, 176147058, 43853977, 160656487, 40490358, 127145028, 46175432, 125716299, 47970998, 142990986, 32686143, 96639106, 28256535, 113010719, 32245717, 109662077, 49315728, 158277164, 39866932, 133740008, 29835677, 121148901, 24484676, 101192015, 20524807, 79615303, 19472158, 67957180, 17802439, 57347318, 17393829, 46409063, 21637835, 57425134, 24685542, 64142491, 22664706, 52782681, 18106352, 45773357, 17952323, 35943518, 22782703, 48608934, 29545983, 54107623, 20658150, 35173101, 19308973, 30420232, 21648523, 33358523, 34925054, 57821290, 23749536, 52300713, 22246131, 51411073, 29970764, 49549669, 28882978, 45160688, 23305717, 42669741, 22496477, 42017707, 24123603, 37571652, 27087406, 46212322, 31957832, 67751755, 31735687, 44207281, 31518232, 39656499, 44331797, 66592574, 305051402, 236738335, 61016620, 351951034, 47694378, 54296987, 57684704, 62552739, 72834978, 76647987, 77661681, 90054910, 94027736, 105247183, 94705645, 118623817, 127635699, 168214213, 125541816, 183982552, 158891836, 202074988, 154380584, 202356268, 156180324, 227847605, 151802781, 210993781, 103866998, 140327139, 91144468, 146060827, 78798545, 172226188, 94375043, 184702914, 59593981, 111951306, 48128719, 67660907, 58181026, 63873729, 58155047, 64229300, 59114829, 66547475, 51011422, 59659321, 40733341, 48214428, 48326348, 55047638, 37896199, 42305785, 31219727, 37677791, 36206563, 45170766, 30796703, 39213659, 29426202, 38564819, 31122601, 41869397, 30150284, 39687478, 30251942, 41245534, 36266084, 50365634, 42078213, 72001066, 38470907, 60095827, 45098881, 67795094, 32427023, 43091370, 44211158, 69249130, 46198628, 72272292, 42080483, 59575435, 67142635, 78404256, 91590826, 91367080, 81279600, 97189859, 159178282, 145226665, 64489072, 69171662, 107042650, 117525720, 71536249, 91016903, 55757027, 135642542, 41353460, 72293186, 68166846, 222105000, 29394948, 73100483, 40777925, 101079557, 29585737, 75349492, 25111702, 36658070, 20004139, 30107908, 17352754, 24086411, 16352644, 23340098, 15867984, 21918125, 15447299, 22444804, 15101802, 21772688, 28749939, 41991543, 18181681, 25302101, 15872482, 22007830, 18623139, 27740895, 27122497, 38924843, 15959970, 23381320, 19605220, 25139255, 20045670, 24677277, 17806558, 25316488, 17454866, 24929439, 21039898, 27983508, 26828223, 37740624, 24913259, 41158419, 37691892, 82078166, 39765574, 105437749, 39806713, 92607859, 36546145, 79750166, 31341108, 76242765, 22884050, 66475659, 17116842, 41957883, 12610875, 20866546, 11422645, 18295880, 11426134, 16997562, 10421891, 16780423, 9952551, 15942561, 9597599, 16154386, 9345908, 15026048, 8971600, 15287752, 8630352, 14028149, 8972152, 13734295, 9210456, 15206966, 8586592, 14676163, 9113002, 15707156, 8724114, 14789908, 9653042, 14574939, 10636733, 15123006, 10884812, 15665015, 16096044, 31557043, 50665144, 69162457, 40125003, 67033492, 88178064, 117506119, 48467438, 62147370, 48550396, 64970507, 28885550, 33953693, 14804984, 21215748, 13263821, 19255188, 11543123, 16023682, 11155710, 13600438, 13419212, 15819226, 11648329, 14025008, 15381219, 15881212, 18821434, 23967947, 11387648, 12943318, 13650064, 17002021, 9341178, 11791878, 7537499, 9877936, 7424723, 9225182, 7303770, 9539660, 7533521, 9356114, 7445487, 9183369, 7723960, 10046696, 7069531, 8696718, 6883109, 8408871, 6576015, 8175139, 6292912, 7827066, 6193985, 7618591, 6092437, 7463851, 8007993, 9628431, 8214867, 9592375, 5643731, 7108804, 7796140, 9073715, 7786279, 9218450, 5852014, 7220848, 5531071, 6707757, 5325259, 7057039, 5144619, 6276074, 4919355, 6112982, 4642040, 5895631, 4766331, 5898431, 4372028, 5764096, 4425480, 5700040, 4791509, 5677859, 4351727, 6068910, 4356586, 7292655, 6665298, 7799927, 6460052, 8712420, 8969410, 13822499, 38495765, 43424278, 39621419, 44732021, 37841957, 45142206, 34591715, 41608581, 36228112, 45347955, 35407558, 39870269, 25625081, 28832164, 28159583, 30823422, 36269127, 36764400, 33333975, 33608379, 33903467, 37356045, 49753141, 51095775, 36042304, 39506987, 40017888, 40858778, 33928722, 31665538, 35496066, 34854597, 36648303, 34853318, 40974424, 37693597, 37355103, 37254712, 40888929, 39220835, 46749102, 45365054, 38692171, 38994526, 37071537, 38250689, 30771455, 30199810, 30860932, 32031393, 26897069, 27840729, 33115398, 30062000, 37198082, 34015339, 31362599, 34999206, 30190111, 29543583, 37835112, 33625379, 36564345, 32805001, 33423060, 27516038, 27951644, 25433845, 28747171, 29462452, 37615549, 32462563, 36596022, 35115114, 32025505, 33817468, 28993647, 27627406, 32829876, 29419615, 28088898, 28000767, 25990459, 25452615, 28452616, 22908176, 80282537, 44883045, 48061766, 31887840, 26450990, 22957308, 21324193, 21018404, 21640103, 21695803, 20979613, 20553114, 22796444, 21646388, 28102885, 25637043, 46302294, 30639089, 78909133, 63895259, 924877222, 574298446, 61682541, 69381555, 36784559, 44112668, 35770403, 39446356, 40450488, 46573911, 36409794, 36249387, 32861168, 33681605, 27772410, 28078711, 22718664, 21390343, 20514355, 20727964, 18684570, 18747393, 17864735, 18478176, 17042677, 18099092, 21912916, 23904073, 23854075, 25437678, 28012160, 27610597, 28921222, 27998643, 38371840, 38347990, 29883020, 31254336, 28944013, 28106503, 22333477, 25509381, 37523067, 44624151, 51398284, 51326151, 45237494, 48676641, 48884986, 36137123, 48455452, 50305940, 34113506, 30096213, 47848045, 50180241, 29558817, 27433066, 23156895, 30452971, 47913798, 81310397, 21173499, 36507223, 16705783, 44526670, 16915890, 27976765, 39421477, 97994802, 18089480, 46748560, 19213895, 68914899, 18327982, 25978185, 22752008, 26705144, 23232643, 37060652, 49410882, 115207125, 35668038, 100482133, 32216745, 37102054, 26936190, 37952923, 29880600, 59994902, 17154364, 36879989, 16187604, 18481243, 36345076, 36791199, 34979093, 33833615, 35171628, 30291521, 18008813, 18242520, 35924017, 34838177, 31498662, 30227506, 20756740, 18249859, 15655526, 16252234, 13366295, 13884202, 12628160, 12998964, 36134899, 31894894, 38682499, 42236948, 174659159, 161098060, 19201111, 23133845, 15768300, 23803944, 15563058, 21015488, 12400951, 15170894, 14463083, 15372174, 14145159, 13432976, 12508976, 14533641, 12603315, 14752532, 29165535, 34701841, 34613004, 38382305, 12701108, 15299177, 10542043, 11814855, 12720299, 14503320, 13262320, 16774322, 10999137, 13968885, 12477166, 14675299, 11295054, 14260493, 8920837, 10540879, 10821060, 12680480, 7308803, 8518389, 8708401, 9690657, 7360906, 8333873, 7872593, 9331100, 14983661, 20052686, 7071602, 8167268, 6752306, 7607500, 7300664, 8251348, 10283979, 10793896, 8633848, 9200107, 7047555, 7782679, 7026706, 8085627, 7037919, 8680326, 10692618, 11052656, 11815421, 14029510, 11321528, 11017049, 11148373, 12237342, 10273471, 10712920, 10930483, 9380573, 10664164, 9876970, 13067421, 9311465, 10683709, 8063691, 7772941, 5590061, 6222425, 4846499, 5578634, 4242595, 5323003, 3907435, 4659877, 3810184, 4686749, 3530004, 4106660, 3572372, 4192119, 3723871, 3911411, 3725753, 3844458, 3938543, 4354640, 4345201, 5141553, 4971951, 6759012, 6429379, 9578618, 8903225, 15996240, 14592373, 33416266, 30327576, 87368361, 86730343, 116182636, 147896821, 50987865, 66104255, 21879816, 25754860, 11882765, 13454804, 7726892, 8477395, 5837996, 6149962, 4994890, 5079621, 4383296, 4387098, 4258400, 4099896, 3964729, 3877924, 3337955, 3353870, 3603645, 3658213, 3117322, 3254205, 3400425, 3487749, 3909460, 3903053, 4335854, 4256376, 3558737, 3873069, 4237518, 4184615, 3879568, 4033895, 4166573, 4595958, 4272930, 4539149, 4873247, 4683438, 6452743, 7393386, 7265479, 12181806, 6763889, 7661375, 6971519, 6047856, 6438627, 5386490, 5686910, 4848516, 5979046, 4854495, 5753200, 4628045, 4952361, 4710863, 4565250, 4561258, 5486697, 5536561, 4411443, 4537075, 4755574, 4706289, 5164482, 5076590, 5073376, 7646303, 5311173, 10917625, 4101964, 5068857, 4337606, 5115597, 4564387, 4668824, 4631901, 5467250, 4723013, 5798968, 5869221, 7572800, 7765647, 10084591, 9597208, 11138673, 15000598, 15929891, 15296224, 14624702, 18227523, 16894466, 16357620, 18928804, 23857201, 26463772, 15077118, 19689309, 28562776, 38402739, 31931912, 44236189, 37961974, 47425417, 47120253, 82298168, 117287497, 147415427, 105762156, 132902413, 118794694, 148980103, 66277231, 66976258, 47955638, 59812110, 42280110, 47196037, 37788708, 38700275, 24178459, 22981247, 32673089, 32218495, 18744666, 16737281, 11989656, 10980265, 8226540, 7846527, 5285698, 4718877, 3719617, 3816493, 3296615, 3337248, 3349739, 3234481, 2725805, 3040272, 2784791, 2834818, 2905428, 3418362, 3323803, 3547666, 3424843, 2993907, 2991925, 3190753, 3698424, 3207622, 3041379, 3391014, 3548188, 3830123, 2794684, 3171099, 2976888, 3409152, 2609357, 3076370, 3448181, 3477913, 2395924, 3008964, 2935119, 2503567, 2747312, 3003776, 2345180, 2887543, 2875523, 4047590, 3544112, 3356890, 2872637, 2801455, 3385894, 2895361, 3228398, 2974132, 3224779, 2755368, 2956570, 2778855, 2732627, 2535518, 2924457, 2712460, 2918495, 2988522, 2940121, 2910417, 2799566, 2634529, 2843051, 2638672, 2841214, 2506761, 2569948, 2651799, 2272136, 2412711, 2200321, 2512456, 1782598, 2444849, 1586675, 2115228, 1662123, 2141720, 1365500, 2291167, 1541416, 2250852, 1614926, 2097689, 1651982, 2224546, 1476782, 2110319, 1613876, 2129865, 1684429, 2368080, 1842319, 2484362, 1823977, 2267909, 1636541, 2482010, 1506425, 2201026, 1704055, 2406874, 1754001, 2693560, 1958744, 2487501, 1786765, 2647321, 1762151, 2506832, 2146423, 2569078, 1847711, 2571620, 1971076, 2857411, 1825205, 2860939, 1694570, 2900597, 1658465, 3454193, 2452289, 24374736, 2562823, 27360760, 1530087, 4774473, 2406990, 18455112, 3438796, 43025599, 1892972, 5540505, 1987491, 3729814, 1960989, 3339258, 1826160, 3126293, 1841758, 3202876, 1975889, 3140266, 1784067, 2711450, 1759820, 2772621, 1890299, 2798137, 1713928, 2681236, 1810850, 2695869, 1982948, 2696095, 2046829, 2834138, 2032780, 2776086, 1883856, 2792566, 2038178, 2667824, 2516633, 2671938, 2434678, 2777007, 2121305, 3218425, 2393865, 4534850, 3026273, 3532661, 2508045, 3782342, 2733001, 3722022, 2053139, 2918697, 2583343, 3507402, 3628020, 3558825, 4760942, 4080084, 3503204, 3744204, 2564623, 3456410, 3033733, 4347196, 4794716, 9519405, 39264539, 129542795, 31952500, 90506566, 5440410, 10940205, 6986735, 42102411, 6807691, 18738039, 5727356, 6646276, 6334260, 7106678, 27528625, 25385670, 12503497, 10349194, 16741591, 15880339, 22913289, 23861758, 16395721, 20257989, 27227267, 24764297, 10987688, 9991612, 14836286, 14178754, 15889351, 15068307, 19056688, 19893617, 13550093, 74537094, 17046564, 64156917, 16928452, 18709071, 7970680, 8679154, 21885172, 16677500, 11086138, 10347864, 5777681, 6511858, 10702080, 8263870, 6414862, 5177301, 7392801, 5522991, 7632363, 5521891, 4429442, 5141246, 4437962, 4713124, 4682656, 5201962, 3357663, 4033730, 6347157, 4536040, 5162888, 5858457, 4530111, 5514569, 3705917, 4395069, 4005062, 4322744, 4137568, 4509432, 4568026, 4917769, 4246884, 4752821, 4101506, 4794941, 4716765, 5100793, 5251493, 5487365, 5151850, 5539515, 5329484, 5979635, 5693495, 6431739, 5551617, 6137586, 6717681, 7579966, 8287942, 9944413, 7973593, 9539309, 6260445, 6944790, 6639264, 7017903, 8661446, 8890185, 7452330, 7076329, 8065504, 7758935, 12986285, 12510351, 14687851, 16016589, 10811421, 10505975, 16936125, 16048723, 14235022, 14692536, 11515410, 10185673, 12366240, 10845984, 11628100, 11152221, 12104536, 12209379, 11897270, 11660802, 13841182, 10864520, 15370625, 10895724, 14362926, 9628075, 16481124, 10886762, 21453723, 11848232, 27491072, 15788705, 43149552, 33719668, 30596535, 27402730, 55715731, 36420718, 42660840, 40643469, 26369805, 20993226, 17688010, 15372860, 13853568, 10276320, 14987013, 10451967, 11915948, 8664789, 7948947, 6767177, 6562650, 5540239, 6098262, 4965553, 8351472, 5203208, 7635639, 5066968, 9317502, 5508798, 9179550, 5908849, 8243336, 5041237, 7386454, 5545817, 8637649, 5760011, 8217680, 6006850, 21881677, 12726606, 45508424, 36954717, 19157445, 23446346, 36113612, 23161366, 32250763, 30897388, 21136706, 16206069, 30222602, 19291662, 16714054, 14372993, 15650123, 10796328, 17412825, 15672118, 18807737, 17917709, 15503508, 10081708, 11417608, 7923077, 10699799, 7749773, 14386948, 9261257, 56467667, 33417304, 52890449, 48032293, 29062872, 23242018, 36501486, 25065587, 23412523, 20826889, 19066199, 13908736, 10945865, 8582446, 12192383, 6659470, 15113489, 6820906, 7424753, 5668608, 6933959, 5670777, 6195668, 5768035, 10875709, 8193418, 7811554, 11609960, 7010878, 6137633, 12463110, 12057172, 6545448, 7732166, 7126985, 6395963, 14712971, 7478643, 16245271, 11206575, 8742793, 7826046, 10455331, 6923893, 7973865, 7164603, 8153317, 7577606, 9840250, 9746034, 14425877, 26246565, 54367548, 122538954, 26109680, 40166089, 11137275, 12810374, 8641624, 9622083, 6658394, 6728764, 10523876, 6634422, 6649192, 5785925, 6190257, 5878080, 10275940, 5990167, 6047874, 19281908, 7720276, 89801987, 4375955, 12655641, 4618788, 6776033, 6682859, 6004507, 4902971, 4857628, 5543398, 4571978, 4709011, 4301051, 6197798, 7274294, 6679755, 7558111, 4087772, 4809747, 3439387, 4404121, 3981186, 4155907, 4893781, 6083104, 4977023, 6429334, 4893516, 5824296, 14311515, 20325943, 12896349, 14917987, 5651188, 5331369, 4977180, 5787633, 4094555, 4877837, 5385169, 4938339, 5704021, 5788051, 6524867, 5104170, 5125587, 4480038, 4361553, 3857693, 5522122, 4442797, 6018572, 4736688, 8359507, 5533513, 26298661, 16836405, 9494794, 12965025, 15970044, 9261835, 12597059, 12515509, 11531908, 7522031, 25978385, 15344807, 17410087, 16188748, 23840369, 15386360, 26054572, 18904748, 14266842, 12893861, 6265884, 6181915, 10717623, 6973572, 11438989, 11864686, 15902082, 10367689, 12820533, 10140250, 6767399, 5794777, 8072540, 4987108, 4407985, 4579671, 3894191, 4071378, 3300006, 3446009, 4659237, 3550968, 5111119, 3934388, 4529638, 3633981, 4401070, 3305972, 3788658, 2815157, 4379994, 2563102, 3526197, 2799465, 3371079, 2612031, 3395443, 2879536, 3167921, 3445117, 2728494, 3387837, 2777852, 4002138, 3191039, 4896911, 3064223, 3744857, 2882676, 2902579, 3192018, 3020582, 3389213, 3445934, 3991864, 3692447, 7492313, 5699982, 19672453, 10839706, 265562556, 143875100, 37315909, 46713627, 10699275, 8801800, 7451853, 7942848, 7310364, 7842462, 6046960, 6140278, 6196309, 6506569, 5342634, 5545833, 4889793, 5176057, 4779892, 5297344, 3807013, 4127983, 4305286, 4807368, 3347352, 3570671, 2987449, 3389652, 2997169, 3208945, 2894681, 3166850, 3108300, 3487693, 5614301, 6082539, 6426602, 7359362, 6252190, 7040382, 3762828, 3877266, 3362161, 3465711, 3401599, 3465280, 7227293, 6262747, 13237754, 12960688, 10409922, 8986292, 22737209, 20786940, 10695245, 11105227, 20328453, 18559200, 15286621, 16834838, 10300064, 10545877, 6270455, 6778050, 5363202, 5383261, 5010046, 5296460, 3995311, 4354900, 2590026, 3069099, 2618467, 2975881, 2437062, 2793579, 2326570, 2529690, 2170797, 2789567, 2404439, 2458120, 2523752, 2489057, 2821219, 2815891, 2334835, 2120994, 2075297, 2148385, 2051080, 2071283, 2018314, 2112460, 2251169, 1845515, 1970813, 2018929, 1746810, 1834591, 1841811, 1851426, 1970003, 1779241, 1941810, 1777824, 2109186, 1774234, 2030660, 1765702, 1858116, 1778271, 1917918, 1785178, 1828023, 1608377, 2865573, 2450871, 2389475, 1880194, 2051307, 1727171, 2902959, 2174825, 2415768, 1962911, 2516672, 2145713, 2006572, 1896725, 1994148, 1866227, 2054433, 1652913, 1645923, 1772884, 2738784, 2259827, 1719877, 2384452, 1766685, 8205262, 2198165, 69853478, 3131797, 8033983, 3482429, 3243942, 41344297, 2362982, 11974176, 2233809, 2933079, 1896241, 1910444, 1533542, 1626105, 1584269, 1696223, 1336963, 2446058, 1672874, 1844127, 1491734, 1350359, 1308638, 1239937, 1088673, 1174309, 1058759, 1568335, 1360706, 2408198, 2071746, 3011886, 2385974, 2004130, 1624216, 2493848, 1818031, 2713902, 2849376, 1720433, 1543522, 4498393, 3350395, 1777060, 2614621, 2080426, 1562895, 1902742, 2330395, 1106693, 1284215, 1076838, 859232, 1088411, 809099, 1660226, 1387403, 962019, 892591, 699096, 820620, 672778, 978114, 762233, 588511, 685934, 703018, 1317503, 835060, 740301, 683674, 596679, 840375, 790465, 868156, 654120, 577653, 701434, 896742, 645360, 703156, 600585, 673209, 628230, 701949, 555575, 650786, 554766, 507645, 581107, 639615, 562741, 698161, 666114, 749345, 395458, 598941, 569225, 495801, 453205, 510450, 536268, 486821, 341256, 577687, 512912, 594426, 785059, 845732, 4600127, 3115079, 24186388, 21174502, 11207431, 11143093, 23510245, 21492747, 4962912, 6832719, 1254627, 1343449, 6037434, 4468585, 32044645, 28029382, 10078353, 10943453, 21016001, 18035347, 19715190, 20921866, 1665130, 1850215, 685908, 666779, 500121, 529365, 543014, 453104, 723921, 728066, 541418, 573654, 251205, 429521, 228239, 483925, 210967, 549936, 403591, 426226, 321299, 274720, 403122, 442367, 366499, 408785, 327629, 526714, 272867, 442841, 207223, 488989, 100714, 442116, 311411, 338482, 634560, 231571, 864007, 663464, 414986, 693304, 215624, 348521, 214632, 247313, 284767, 380655, 335655, 302782, 237952, 234741, 119118, 290922, 56938, 228415, 145593, 229541, 79279, 219851, 114883, 229190, 253440, 231830, 298345, 343361, 659553, 583089, 5661473, 4763641, 42501347, 37465706, 19046469, 19515752, 1678340, 1700477, 666387, 699187, 570783, 576521, 418374, 314371, 330738, 240459, 280430, 291783, 270997, 164393, 213340, 257488, 204183, 251663, 143228, 231753, 314947, 284795, 462774, 463102, 655267, 557190, 992314, 626150, 281850, 270902, 218983, 228705, 205245, 127646, 177902, 265351, 531852, 483171, 504113, 533657, 178571, 399556, 429216, 341907, 339516, 547767, 302428, 524955, 259506, 303736, 298121, 279209, 705637, 839540, 1892941, 2688194, 832135, 1224368, 499247, 689864, 561686, 411460, 401568, 376855, 389534, 381450, 324276, 270848, 253953, 360355, 153729, 142692, 182576, 215206, 26731, 131634, 121065, 279575, 8378, 354559, 3350890, 6042431, 731897, 1303240, 299307, 269394, 188308, 372369, 93559, 394179, 165682, 569932, 282164, 333632, 150821, 308888, 1788277, 3701803, 216357, 334917, 133974, 148063, -19306, 217085, -40842, 186624, 99943, 272404, 161389, 356429, 203508, 193395, 36872, 232185, 95510, 134201, 52049, 190583, 180666, 270383, 351192, 559072, 99377, 176959, 80716, 287869, 94236, 158161, 271578, 79586, 12655, 160936, 168816, 284199, 173465, 189205, -46341, 50435, 129964, 191754, 83231, 56092, 25193, 162338, 107541, -22639, 55217, 35787, 47909, 63362, 53623, 98341, 84343, 83148, 68525, 281156, 200815, 325498, 7023, 211971, 147348, 173311, 131772, 82241, 57698, 55677, 125820, 75611, 141190, 206538, 121937, 132452, 109561, 285020, 288524, 161788, 218752, 339620, 376737, 461421, 788267, 629020, 1200393, 1242008, 2462325, 2464638, 3344975, 3831304, 2510363, 3074276, 1173759, 1533410, 627920, 818287, 440831, 576747, 280345, 389708, 339139, 383207, 146265, 193118, 199649, 245270, 192506, 139053, 200213, 102594, 191376, 166123, 146673, 525440, 160612, 141108, 214046, 163549, 81501, 89169, 229145, 149189, 127803, 224104, 43046, 62199, 100512, 64995, 182381, 223371, 227468, 152893, 188902, 161563, 271719, 180982, 195312, 132571, 185243, 204, 190690, 42928, 260847, 86701, 266180, 101212, 432107, 84562, 912283, 58893, 2052785, 149812, 2087275, 109099, 1221562, 212146, 505035, 155971, 366796, 208734, 274636, 157009, 220756, 39843, 123336, 140177, 51948, 85997, 186316, 159521, 73779, 142105, 233432, 163863, 103808, 213311, 175274, 122588, 223116, -70881, 51806, 95016, 199224, 129689, 16215, 14954, 83282, -58656, 64609, -37894, 75890, 81202, 25216, -57565, 4882, 223007, -104123, -6556, 111613, 1972, 29788, 78473, 38631, 41930, 7173, -87043, 16431, 42437, 40524, 75041, -47853, -24668, -83193, 97270, 93566, -64184, -53851, 72846, 81179, -88798, -85487, 93245, 99034, -53903, 48958, -11602, 61371, 76051, 161268, 73033, -120141, 17482, 71106, 871, 55534, 7786, -36060, 49042, -9883, 40971, -3269, 12172, -17860, 174429, 66996, 16702, 105242, -110576, 106180, -7294, -158111, 55265, 29837, 57985, -38040, 60157, -15124, -94016, 17030, -61063, -92350, -56016, -31862, -2691, -34232, -151965, -80909, -85343, 112232, 2900, -62024, -44420, 82929, 80607, 26812, -851, -116838, -100528, 60697, 112403, -144841, -22094, 1512, -21703, -62315, -173280, -5621, -5223, -138151, -18163, 107855, -46407, -831, 140759, -5251, -101338, 15117, 22505, -159721, 38653, 75320, -18872, 49405, -50979, 37787, -84577, 91876, -56425, 82390, 46025, -27861, -35438, -10174, -26542, -95622, -115634, 83964, -128186, 47685, -53810, 10099, 97387, 3935, 7213, -200517, 22792), .Dim = c(2L, 1406L))
The reason you have fewer items (samples) in the plot is that kohonen clusters items that are sufficiently similar. Consider the data set wines from the package. It has 13 variables for 177 wines, but the count plot shows 25 clusters. It also shows how many wines are in each cluster by the color gradient. library(kohonen) data(wines) kohmap <- xyf(scale(wines), classvec2classmat(wine.classes), grid = somgrid(5, 5, "hexagonal"), rlen=100) plot(kohmap, type="counts", labels = wine.classes, col = wine.classes + 1, main = "count plot")
R forecast function not picking up seasonality
I am having trouble picking up the seasonality the seems to be implied in the data. I think (though its just a guess that its using additive and not multiplicative seasonality). I am using the forecast function and thought it would automatically pick what I need based on a lecture from Dr. Hyndman. The following snipet of code plots the chart and I would have expected the forecast to be higher then it is. Am I missing a model parameter or something? Any help would be appreciated. sw<-c(2280, 1754, 1667, 1359, 1285, 1379, 2166, 1053, 1076, 1149, 1277, 1577, 1639, 1719, 1592, 2306, 3075, 2897, 1875, 1966, 2927, 3528, 2948, 2890, 3947, 3913, 3885, 4148, 5293, 5752, 6001, 7719, 5512, 6782, 6320, 6425, 6406, 7237, 8655, 9269, 12447, 13470, 13469, 13949, 17753, 17653, 14531, 14496, 13643, 12652, 12665, 10629, 8962, 8198, 6833, 5027, 4407, 4449, 4399, 5896, 6589, 3786, 4386, 4847, 5597, 5407, 4800, 7803, 9255, 10423, 5523, 8121, 6944, 8434, 9847, 9292, 9794, 10195, 10124, 11310, 12245, 12798, 14611, 15402, 13532, 16154, 15101, 14755, 17139, 16475, 19935, 19980, 25173, 28568, 27839, 28991, 27073, 29615, 25849, 27910, 27067, 21303, 20544, 15188, 13706, 9277, 10815, 7228, 4608, 4409, 9866, 8471, 8223, 6445, 6641, 6833, 11421, 8945, 8127, 10380, 12005, 13272, 9431, 12144, 14934, 14052, 11712, 14888, 15824, 17275, 18067, 19839, 21192, 22763, 22976, 23721, 22681, 20131, 19965, 20539, 19517, 22022, 23076, 30574, 40247, 43111, 39577, 40724, 44982, 44388, 46372, 43153, 36821, 32258, 31256, 27153, 23180, 18252, 16381, 13220, 12500, 10727, 9636, 8892, 8644, 9482, 9170, 10937, 12299, 15781, 11477, 16524, 16752, 18072, 14776, 13388, 18056, 19815, 21263, 22046, 26415, 24247, 25403, 30058, 26331, 32533, 31891, 35973, 27558, 24554, 25692, 25955, 24284, 24930, 28354, 34840, 40055, 42099, 42768, 48279, 50086, 56466, 42244, 51451, 44583, 39091, 33391, 29452, 25533) swts <- ts(sw, frequency=52, start=c(2006,30)) swfc <- forecast(swts,h=52) plot(swfc)
Did you data have multiple seasonal periods? If so you could check the tbats function. Anyway, your seasonal period is greater than 12, so forecast is using a stl decomposition to adjust your seasonal data. Maybe you wanna check ?stlf for more info on what parameters you can change, or try a BoxCox transformation: lambda <- BoxCox.lambda(sw) swfc <- forecast(swts,h=52, lambda = lambda, robust = TRUE) plot(swfc)