text:
RJ45 Connectors for IoT Applications w/ Space Restrictions
Stewart Connector introduces a new series of low profile Mid-Plane RJ45 connectors. The Mid-Plane RJ45 design allows the connector to straddle the board edge and utilize space above and below the printed circuit board compared to traditional RJ45 connectors that are only designed to mount above the printed circuit bo
Kevin Parmenter, Director, Applications Engineering. TSC, America
I Want My IoT
The tech industry loves buzzwords for new technology: AI, thin clients, set-top boxes, social distancing technologies, and so on. (For some of the latest examples see the Gartner Hype Cycle.) When a buzzword goes mainstream, both experts and non-technologists know that what is really meant: the technology has big money associated with it. Think Sili
High-Speed CMOS DDR4 SDRAMs Feature New 8Gb Devices
To meet the increasing demand for higher-density CMOS DDR4 SDRAMs, Alliance Memory announced that it has expanded its portfolio with two new 8Gb devices. Delivering improved performance over previous-generation DDR3 SDRAMs, the AS4C1G8D4 and AS4C512M16D4 offer lower power consumption and faster data transfer ra
Multiplexers Provide Signal Distribution in IIoT Apps
Diodes Incorporated announced the introduction of the PS508 and PS509 analog multiplexers that are capable of switching signal voltages of up to 36V in an industrial environment. The high voltage capability of the devices will support industrial IoT (IIoT) applications using multiple sensors, including factory au
Figure 1: Topology of a SiC-MOSFET half-bridge with highlighted parasitic inductances
Extremely Compact Isolated Auxiliary Supply for SiC-MOSFET Gate Driver
Würth Elektronik, Technical Team
With the increasing spread of high-voltage power semiconductor components build with silicon carbide (SiC) technology, which operate at switching frequencies above 100 kHz, the requirements for their gate control are becoming more and more demanding. Besides the bipolar, positive and negative driving voltages fo
Keeping Up to Date with the Latest IoT Trends
Matt Johnson, Silicon Labs
The IoT, the IIoT, AI, smart buildings and smart cities are technologies that we are told will dominate our lives for the foreseeable future and make them markedly better. That may or may not be, but one of the real issues for the end-user (and even the system designer) is how rapidly these technologies are devel
Figure 1: Wi-Fi spans several frequency bands and meets a variety of connectivity challenges (Source: Wi-Fi HaLow: Expanding Wi-Fi for IoT applications, Whitepaper by Wi-Fi Alliance)
Everything You Need to Know About Wi-Fi HaLow
Vahid Manian, Chief Operating Officer, Morse Micro
Wi-Fi HaLow is not only the next generation of Wi-Fi to extend distances and increase battery life for Wi-Fi-connected devices, but it also represents an exciting future of wirelessly connected people and devices across the IoT. Applications are endless, from sensors, actuators and security cameras to ho
Figure 1: The functional block diagram of the AL17x50, integrating a MOSFET to reduce the BOM and improve the efficiency at low loads
Boosting Power Conversion in the Internet of Things
Allan Lin, Diodes Inc.
The explosion in demand around the world for smart devices in the Internet of Things and the smart home means designers have to accommodate a wide range of power sources. These power sources have to cope with an even wider range of regulations. At the same time, the end systems have to be as energy efficient
Figure 1. IoT devices manage power distribution, transportation systems, logistics, manufacturing, and smart homes. Ensuring the security of these devices is critical.
How to Secure Tomorrow's Connected Industrial Systems
Alan Grau, Sectigo
From a recent explosion at an Iranian nuclear facility that experts suggest may have been caused by a cyberattack to a Las Vegas hotel that was hacked through a smart thermometer used to monitor the water temperature in an aquarium, attacks against IoT devices are on the rise. Malware attacks targeting IoT devic
Figure 1. BMS Smart Building/City IoT Architecture
The Essential Technologies That Make a Building Smart
Juned Noonari, Director of Solutions Architecture, Black Box
Building automation systems are projects of the internet of things (IoT) combined with automation and control. Edge devices and sensors track a local condition, transfer the data to a local or remote gateway requiring a low-speed network. There, the data is collected, correlated, and processed for further action. Ed
Why the IoT Needs Quickchargers
Jason Lomberg, North American Editor, PSD
Fiddling around with my iPhone and a fast charger one weekend gave me a serious case of range anxiety. Bear with me – at its core, the Internet of Things is a global network of gadgets, vehicles, appliances, and anything else with an internet connection (which is to say, everything). It's the logical evolut
Shielded flat-wire coil
This coil is designed for high-efficiency DC/DC converters in automotive applications. The characteristic features of this flat-wire coil with its MnZn core are its high rated current (IR 38-47 A) and a high saturation performance. At an RDC value of 0.6 to 1.1 Ω, its resistance is lower than that of comparable c
Sensing and balancing IC for automotive battery management
The device is especially designed for batteries in hybrid and electric cars, but it is also suitable for other applications. It measures the voltage in up to twelve battery cells with an accuracy of ± 5.8 mV over the entire temperature and voltage range as well as the operating life cycle. Furthermore, it supports
Advanced H2S protection of IGBT modules enhances lifetime
Harsh environments with critical levels of H2S can be found especially in paper production, mining, wastewater and petrochemical processing as well as in the rubber industry.H2S is the most critical corrosive contaminant for power semiconductors. During operation, IGBT modules are usually heated up to high temperature l
CoolSiC 62 mm module opens up new SiC applications
The proven 62 mm device has been designed in half-bridge topology and is based on the trench chip technology. It opens up silicon carbide for applications in the medium power range starting at 250 kW – where silicon reaches the limits of power density with IGBT technology. Compared to a 62 mm IGBT module, the
Low Voltage Automotive Buck Converter with Programmable PFM/PWM
With a fully integrated 110mΩ high-side power MOSFET and 80mΩ low-side power MOSFET, it provides high-efficiency step-down DC-DC conversion from 5V and 3.3V input rails. The converter has been developed for use in automotive applications including infotainment systems, instrumentation clusters, telematics, a
New silicon carbide power module for electric vehicles
In the past ten years, Infineon has sold more than 50 million EasyPACK modules with different chipsets for a wide range of industrial and automotive applications. At the same time, the semiconductor manufacturer has successfully established its extensive portfolio of CoolSiC products in industrial applications.
High-Speed Op Amp Eliminates Oscillation from Load Capacitances
The device targets applications such as anomaly detection systems used in measurement and control equipment along with sensors that work with very small signals. The proliferation of IoT in recent years has led to a significant increase in the number of electronic components used for advanced control in a v
1U 1kW programmable DC power supplies
These new products further expand the TDK-Lambda GENESYS+ series, offering up to 1,000W output power in a choice of full or half-rack package sizes. The GENESYS+ series is ideally suited for bench-top or rack-mount equipment in a wide variety of OEM, industrial and laboratory applications. Ten models are avai
AEC-Q200-certified SMD ferrites with peak current load ratings
The respective peak-current capability of the ferrite beads is exactly specified. They are characterized by a high rated current of up to 10 A and extremely low resistances. WE-MPSA ferrite beads are available in the construction sizes 0805, 1206, 1612, 1812, 2220, and 3312 and can also in some cases be supplied
Motor System ICs for control of small electric motors in cars
These ICs are the world's first multiple half-bridge drivers for MOSFETs with integrated power supply and communication interfaces. "With our highly integrated Motor System ICs, system designers only need half the board space compared to existing solutions. At the same time, system designers maintain the c
New Ranges of Film Capacitors for Green Energy and Automotive
Constructed with an aluminum canister design, both the C44U-M and C44P-R power film series address the increasing demand for high-power conversion systems in green energy and industrial applications. These capacitors also support power conversion in en-ergy storage systems, IGBT and wide bandgap (WBG) semiconduct
ROHM and LEADRIVE Establish Joint Laboratory
SiC power devices have been adopted increasingly in onboard vehicle chargers and DC/DC converters. These devices provide several advantages compared to silicon-based power devices such as IGBTs. One key benefit: significantly lower losses during both switching and conduction along with being able to operate at hi
Integrated LIN Interface Sensor Signal Conditioner
The single-package sensor signal conditioner (SSC) delivers best-in-class performance, increased design flexibility, and cost efficiency in a compact form factor for HVAC applications used in plug-in hybrid electric vehicle (PHEV), Battery Electric Vehicle (BEV), and Fuel-cell Ele
Würth Elektronik extends its switch portfolio
The 8.7 x 3.0 x 2.0 mm WS-SLSU SPDT switch is a slide switch in horizontal design, which is attached to the outer edge of the PCB as a SMT mountable component. Würth Elektronik also offers WS-TASU (6.2 x 3.0 x 3.5 mm, actuating force 160 gf), a switch for edge connection. The new miniaturized buttons, which are suitable
SIGA Broadens Wound Components Capability
The move follows SIGA's acquisition of the business and assets in February of Wolverhampton-based Stabilised Transformers Limited. Their current transformer capability includes open or enclosed types of dry transformers and inductors, and extends through double wound and auto wound components, toroidal wound
Würth Elektronik extends its WE-CBA product family
The SMDs are AEC-Q200 qualified as part of Würth Elektronik's automotive electronics portfolio. WE-CBA features high-quality Ni-Sn electrodes, a very high current carrying capacity up to 6 A, and operating temperatures from -55 to +125ºC. The ferrites, which are available in various specifications, are ideally
Power transformer maker relies on Yokogawa power analyzer
Founded in 1959, SEA supplies high-value assets which are expected to provide a return over decades. Quality, durability, safety and reliable performance are therefore key characteristics that customers are looking for when they specify a new transformer or reactor. Transformers play a crucial role in the transmission
Dev Kit Combines Wireless Power and Data Transmission
Although it was already possible to transfer data from the receiver device to the charging station, bidirectional data transfer can now be combined with the charging process. During wireless power transmission, the device and charging station exchange data through amplitude and frequency modulation. Würth Elekt
Small, low-power 3D magnetic sensor opens up new designs
With an 87 percent smaller footprint and 46 percent less height than previous comparable products, the sensor opens up new design options. Due to the small WLB-5 package (1.13 mm x 0.93 mm x 0.59 mm) and its low current consumption of 7 nA in power-down mode, the new magnetic sensor is also suitable for use
Upgrade to DesignSpark Mechanical 3D CAD modelling software
Version 5.0 offers new features, enhancements and customisation options that have been developed following feedback from users. The new release coincides with the 10-year anniversary of DesignSpark. Developed in conjunction with Ansys Inc., the leading provider of flexible and affordable 3D modelling software
Efabless Expands Support for Cloud-based Design Platform
Efabless Corporation announced it has expanded design support for the GLOBALFOUNDRIES (GF) 130G solution. The new offering, which includes digital design and low cost ASIC development based on configurable design templates, provides a full "semiconductor ecosystem in a box" that brings the power of GF's 13
Silicon power transistors with wide bandgap-like performance
The claim is made by developer Search For The Next (SFN). The first devices to use Bizen are members of the QJT (Quantum Junction Transistor) family which will include three parts rated at 1200V/75A, 900V/75A and 650V/32A, available in the industry-standard TO247 or TO263 power MOSFET packages. Of extreme signif
Designing the First Public, Statewide 'Internet of Things'
Cornell University engineers and researchers are designing the nation's first statewide Internet of Things public infrastructure. Thanks to a $1.5 million grant awarded by the National Science Foundation, Cornell faculty will collaborate with community partners around New York - through Cornell Cooperative Extension
Low-cost DC-DC converter ranges
They all focus on a simple and effective design approach which is unique to those Traco Power Products. By innovative engineering we have come up with an electrical design which minimizes component and labor costs. Key focus of those designs was to maximize the amount of automatization of the manufacturing process.
Figure 1 Technology positioning – Si, SiC and GaN
What are the advantages of SiC-based designs and how can you implement them?
Giovanbattista Mattiussi, Product Marketing and Dr. Diogo Varajao, Senior System Application Engineer, Infineon Technologies
The global trends - such as digitalization and energy efficiency - that have emerged and accelerated in the past few years pose new challenges to the manufacturers as well as the semiconductor market. Developing power semiconductor devices that contribute to highly efficient power management systems is on the ag
Ally Winning, European Editor, PSD
The Eyes of the IoT
Welcome to the September edition of PSD Europe. We are definitely now on the home straight towards the end of the year, and I can't see many people or companies that will be sad to see the back of it. To quote the queen, 2020 has definitely been an "Annus horribilis", and there is still more to come, including wh
30 / 65 Watt AC/DC Compact Open-Frame Power Supplies
TRACO POWER's new 30 / 65 Watt TPI line of compact open frame AC/DC power supplies are cost-optimized for price sensitive Industrial, Automation and IoT applications. The TPI 30 and TPI 65 products feature: -40°C ~ +85°C Operation Rated full load to +60C, convection cooled up to 94% efficiency 120-130% p


text:
Home/Science of Sound/Sound Movement/How does sound travel long distances? The SOFAR Channel/Sound Channel Variability
Sound Channel VariabilityKirsten Fagan2018-12-19T10:11:38-05:00
The way in which sound speed changes with depth is not the same everywhere in the ocean because the ocean temperature and salinity profiles that determine sound speed can differ greatly from one location in the ocean to another.
Annual average sound-speed profiles from 60°S to 55°N along 150°W in the Pacific Ocean. Sound speeds in the deep ocean all tend to be the same because of the nearly uniform temperature across latitude at depth. Adapted from Figure 2.2 of Munk et al., 1995.
In the deep, open ocean, between roughly 40°S and 40°N, temperature decreases with depth, and pressure increases with depth. Sound speed near the surface in this region decreases with increasing depth due to decreasing temperature. As the depth increases further, the water temperature gets colder and colder until it reaches a nearly constant value of about 2°C below water depths of roughly 1000 m. Where the temperature is nearly constant, the pressure of the water has the largest effect on sound speed. Because pressure increases with depth, sound speed increases with depth. Salinity has a much smaller effect on sound speed than temperature or pressure at most locations in the ocean.
Poleward of latitudes of about 40°, the ocean is almost uniformly cold from top to bottom. Pressure always increases with depth. Sound speed is therefore lowest at or near the surface and increases with increasing depth. The result is that the sound speed minimum sound channel axis is at or near the ocean surface. More generally, the depth of the sound-speed minimum varies in a complex way with location depending on the detailed structure of temperature and salinity.
Depth of the sound channel axis. Adapted from Munk and Forbes, 1989.
A sound wave traveling through the ocean is refracted (bent) whenever it encounters changes in the speed of sound. Sound waves are continually refracted toward the region of lower sound speed. Differing sound-speed profiles therefore cause sound waves to travel on quite different paths.
Temperate and Polar sound-speed profiles and ray diagrams for on-axis sources. Graph showing sound speed and path of travel through the water column. On the left is a plot of sound speed as a function of depth. On the right are the paths followed by sound waves as they travel away from a sound source. For the temperate example, the source is located at 1,000m depth on the sound channel axis. In the polar example, the source is located at the surface. Only rays that do not hit the ocean surface or seafloor are shown. Figures from Figure 2.3 of Munk et al., 1995.
In mid-latitudes sound that travels upward from a source at the sound speed minimum is bent back towards the minimum. Similarly, sound that travels down from the source is bent back up toward the minimum. The result is that sound can travel long distances, cycling above and below the sound speed minimum without hitting the seafloor or ocean surface.
At high latitudes all sound is bent back toward the sound speed minimum at the surface. The result is that sound waves loop down into the ocean before returning to the surface, where they are reflected and again loop down into the ocean. Whenever sound reflects from the rough ocean surface, some sound energy is scattered and lost. A sound wave that hits the ocean surface generally becomes weaker more quickly than one that does not. In the case of very low frequencies, where the wavelength of the sound is longer than the height of the surface waves, the ocean surface appears relatively smooth to the sound wave. Most of the sound energy is then reflected, and low-frequency sound can still travel long distances.
Classroom BATS: Sound in the Ocean – The SOFAR Channel.
NAS Beyond Discovery – Sounding Out the Ocean's Secrets.
Munk, W., Worcester, P., & Wunsch, C. (1995). Ocean acoustic tomography. Cambridge, England: Cambridge University Press.
Munk, W. H., & Forbes, A. M. G. (1989). Global ocean warming: An acoustic measure? Journal of Physical Oceanography, 19(11), 1765–1778. https://doi.org/10.1175/1520-0485(1989)019<1765:GOWAAM>2.0.CO;2

redpajama_set_name: RedPajamaCommonCrawl


Ultrasounds use high frequency sound waves to measure tissue density. Many types of cancer will show up with an ultrasound as an area of uneven density (often as denser tissue). Ultrasounds do not use any form of ionizing radiation, and so will not cause any harm to tissues. Ultrasounds are most often used to generate images of an unborn child and so are widely available.
An inability to view the interior of bony structures. Ultrasound can also be blocked by bone, and so is not useful in imaging past the ribs of the chest.
An inability to pass through air. Ultrasound imaging will not be useful for evaluating the digestive system (stomach, intestines, pancreas, aorta).
The clarity of an ultrasound attenuates as it passes through tissue, and so will not be useful for imaging deep within the body. As such, ultrasounds will be less effective with obese patients.
The resolution of an ultrasound is fairly limited, and so will not be able to detect microcalcifications within breast tissue.
The accuracy of an ultrasound depends to a large degree on the skill of the technician and radiologist.
Ultrasound imaging is fast an inexpensive.
X-rays use a form of ionizing radiation to generate two-dimensional images. They are very effective in imaging bone and dense tissues, but are not effective at imaging soft tissues. In some cases the patient may be given oral or IV contrast to make it easier to discern soft tissues. A mammogram is a form of x-ray used to look for signs of breast cancer.
Another limitation is that X-rays are not good at distinguishing anomalies in dense tissue. This is why mammograms are less effective in younger women, who have denser breast tissue.
The resolution of an x-ray is not very high.
X-ray imaging is fast and inexpensive.
X-rays are not recommended for pregnant women.
CT Scans are like x-rays, but take many more images in a precise and controlled fashion that permits the reconstruction of a 3-dimensional image. CT Scans are often taken in 'slices'. The patient may be given oral constrast and IV contrast to enhance the imaging of soft tissues.
Occluding factors aren't as much of an issue with CT scans as they are with x-rays, because the CT takes multiple fan-shaped images at each point as it rotates around the body, which is enough for a computer to reconstruct both the position and density of the objects in the body that absorb the x-rays.
Conventional CT scans are slow and require the patient to be immobilized during the scan. If the chest is being imaged, the patient may be told to hold his or her breath. Alignment problems between slices can sometimes miss a small mass that lies between slices. A conventional CT scan has a slice thickness of 8 mm to 10 mm.
Higher resolution CT scans, known as HRCT, helical CT and spiral CT, are much quicker. Instead of scanning each slice with the patient bed stationary, the bed is moving continuously as the CT scanner scans around the body (i.e., in a spiral pattern). This is fast enough that the patient doesn't need to hold his/her breath. It is also much higher resolution than conventional CT, so in many cases contrast dye will not be needed. A HRCT scan has a slice thickness of 1 mm to 1.3 mm.
A key limitation of HRCT is the higher resolution can lead to false positives. At higher resolutions more anomalies can be seen, but a much greater number of them turn out to be benign.
Another limitation of CT scanning in general is an inability to view very fine details in soft tissues such as muscles or ligaments. An MRI might be more appropriate in such situations.
Patient motion during a CT scan can cause the images to be "blurry". Also, any metal artifacts in the body can cause 'streaks' in the image. Flat tumors may also be harder to image with a CT scan. Scar tissue may also show up on a CT scan.
CT scanning is slower and more expensive than x-rays and ultrasounds. The radiation exposure from a whole-body CT scan is approximately 100 times that of a chest x-ray.
CT scans are not recommended for pregnant women. The intravenous contrast dye may not be recommended for patients who are allergic to iodine or shellfish.
Hot spots on the PET scan show areas of metabollic activity. This is very useful in distinguishing active cancer from fibrotic (scar) tissue. False positives, however, can occur due to inflammatory lesions due to recent surgery or chemotherapy. One generally waits at least six weeks after the end of chemotherapy before conducting a PET scan. With some cancers the wait may be as much as 12 weeks, in order to allow enough time for a response to become evident.
Since the PET scan involves the use of radioactive sugar, it is important that the patient not eat before the scan. The quality of a PET scan can also be adversely affected by diabetes. Patients should not take any diabetic or glucose control medication before a PET scan.
Since PET scans and CT scans use similar equipment, it is possible to integrate them into a single PET-CT scanner. A PET-CT scan can yield more information than either scan on its own.
Since a PET scan measures metabollic activity, it may not be as effective for identifying tumors that have a low metabollic rate, such as carcinoid tumors, mucinous cancers (e.g., ovarian cancer), and low grade tumors (e.g., bronchioaveolar cell carcinoma fo the lung). PET scans are particularly useful in imaging the lungs and in measuring response to treatment for cancers that exhibit high FDG uptake.
Because of the length of time required to generate the image, patient movement and breathing can generate a blurry image.
Although the false positive rate for PET scans is low for many cancers, the false negative rate isn't zero. So a negative PET scan result does not mean that there is no cancer.
The radiation from a PET scan lasts for only a short period of time and isn't very strong. The maximum resolution of a PET scan is 5 mm to 7 mm. As such, a PET scan is usually not used to identify tumors smaller than 1 cm in size.
PET scans are not recommended for pregnant women.
An MRI uses strong magnetic fields to cause water molecules to resonate. It is very good at imaging soft tissues, such as the heart, lungs, liver and other organs. An MRI cannot image calcifications and bone and cannot always distinguish between cancerous and non-cancerous anomalies. An MRI can image anomalies that are obscured by bone. Patients should notify the technician about any metal implants in their bodies.
MRI does not involve radiation. MRI is not recommended during the first 12 weeks of pregnancy.


Mens Canvas Pumps - Plimsoles - Deck Shoes - Espadrilles. Well made Canvas upper with a hardwearing Rubber sole with the classic Plimsoll line decoration. A really well made Urban Canvas Plimsoll/Deck Shoe. Available in 4 colours - Black, Navy, White, Burgundy. Sizes 7 - 12. See drop down menu for available colours and sizes. Very reasonably priced. - Mens Canvas Shoes - Pumps - Plimsolls. Sizes: 7 - 12. Slip on Style - Well made Canvas upper with a hardwearing Rubber sole with the classic Plimsoll line decoration - Padded collar for extra comfort. Twin gusset. 3 Colours available.
Skechers Flex Advantage 52189-BBK Lindman is a wonderful shoe of SKECHERS - Olive Leather/Mesh/Black Trim. - Skechers Sport Mens.
Features: Canvas vulcanised rubber sole lacing with metal eyelets low cut logo patch on the shoe tongue Material: Sole: 100% plastic material Lining: 100% Polyester ###optical white Features: Sneaker Lacing with metal eyelets Flat Laces Low cut Vulcanised rubber sole Logo apliqué , Logo print Manufacturer colour: optical white Outer Shell: 100% Textile Lining: 100% Polyester Sole: 100% Plastic - Manufactured by Converse.
Belmont From Gola Is A Mens Classic Casual Trainer. Part Of The Men's Gola Sportstyle Range, Belmont Features A Coated Leather Upper, Dual Hook & Loop Fastening Straps, Cushioned In-sock For Added Comfort And Has A Rubber, Non-marking Outsole. - Mens Gola Belmont Trainers. - Coated Leather And PU Upper. - Wide Fit. - Cushioned In-Sock For Added Comfort. - Rubber, Non-Marking Outsole.


text:
LATINO REBELS
MITÚ
THE GRUNION
THE HI-LO
PRESS/ INFLUENCER APPLICATION
Twitch Steam
LATINX GAMES FESTIVAL 2021
Latinx Games Festival is the definitive video game industry event for Latinx game development, providing a platform for global opportunities to the Latinx game development community.
Our Panels highlight Latinx industry professionals and deep dive into the skills and tools needed to thrive in the video game industry. We cover a range of topics in our panels that are important to Latinx game development, and to the video game industry as a whole. We also showcase an Arcade of Latinx-produced games curated from around the world, with the hope that it will lead to a richer, more mature video game industry and one that positively impacts the future of Latinx game development.
Join us online November 20th & 21st, 2021 for 2 Days Talks, Games, Career Seminars, Recruiter Summit and Awards at the 3rd annual Latinx Games Festival!
latinx game awards 2021
arcade 2021
BE A PART OF THE FESTIVAL!
Apply through the links below!
Sponsor Submission Form
Press/ Influencer Submission Form
On September 14th, 2019 at The Museum of Latin American Art (MOLAA) in Long Beach, CA the 1st Latinx Games Festival signaled an industry-wide call to action for Latinx representation throughout the video game industry.
The 2nd Latinx Games Festival was a 2 Day Event that took place on November 21-22, 2020. This event was planned to take place in person at MOLAA, but due to the COVID19 global pandemic, we had to adapt our conference to a virtual online presentation. The event was featured on the front page of Steam and streamed to both Twitch and Steam.
Industry Experience Sponsor
Niantic is the world's leading augmented reality company with an initial focus on augmented reality games. We see a future where our technology paves the way for new entertainment experiences, advanced robotics, and scaled adaptive computing — and games are where we incubate some of our most audacious thinking.
Twitter Linkedin Youtube Facebook Instagram Steam
© 2019 – 2021 latinxgamesfestival.com All rights reserved. Website by KasonMedia | Original Artwork by Ben Wu


Ben recently played the role of Terry in the new thriller VENDETTA. He worked alongside DANNY DYER and ALISTAIR PETRIE. The film is due out later this year.
Ben is about to shoot a promo for a proposed new feature film directed by Ian Diaz called Spy Girls. The promo will also iclude actress and sports presenter Charlie Webster and fellow actor Anthony Ofoegbu.


text:
Allow Ads
HomepageUSNews
NY Plot Foiled Amid 'Unprecedented' Number of Threats to Jewish Community
Caitlin Burke
NewsBlock_9AM_112222_HD1080_34.999_320
A memorial inside the dormant landmark Tree of Life synagogue in Pittsburgh's Squirrel Hill neighborhood on Oct. 26, 2022, four years after 11 people were killed in America's deadliest antisemitic attack on Oct. 27, 2018. (AP Photo/Gene J. Puskar)
A Glock, a ghost gun, a hunting knife, and a Nazi armband: that's what New York police found on two men suspected of plotting an attack on a synagogue. It's the latest in a shocking rise of antisemitism in America.
The FBI and Homeland Security point to an unprecedented number of potential threats, along with a rise in hate-filled rhetoric and they warn their law enforcement partners, along with the Jewish community, to stay vigilant.
The New York arrests come only two weeks after the FBI alerted New Jersey synagogues to a broad threat against them.
"This was not an idle threat; this was a real threat," said New York Mayor Eric Adams (D) at a press conference over the weekend.
The suspects in the New York City plot reportedly took to social media. Christopher Brown, 22, tweeting, "Gonna ask a priest if I should become a husband or shoot up a synagogue and die." The next day he wrote, "This time I'm really gonna do it."
Brown and Matthew Mahrer, also 22, were arrested in Penn Station Saturday morning.
"Law enforcement officers recovered a Glock semi-automatic firearm, a ghost gun with an extended 30-round magazine and laser sights, a large hunting knife, a black ski mask and a Nazi armband," said Mayor Adams.
America's top law enforcement agencies say, unfortunately, this is not an isolated incident.
"We are working very, very closely with the FBI and our federal, state, local, tribal, territorial campus law enforcement partners to address violence, an increasing level of violence, borne of ideologies of hate," said Secretary of Homeland Security Alejandro Mayorkas during a recent Senate hearing on the rise of antisemitism.
A memorial remains inside the dormant landmark Tree of Life synagogue in Pittsburgh's Squirrel Hill neighborhood on Oct. 26, 2022, four years after 11 people were killed in America's deadliest antisemitic attack on Oct. 27, 2018. (AP Photo/Gene J. Puskar)
More than 60 percent of religiously motivated violence is tied to antisemitism, and experts are concerned a growing increase in antisemitic rhetoric could exacerbate the problem even more. That includes rhetoric like we saw from rapper Kanye West, now known as Ye, who recently railed against the Jewish community on Twitter and in interviews.
After being dropped by all of his sponsors, West later tried to repair the damage, saying he wanted "to give a sincere apology to the Jewish people."
"This hate cannot be allowed to take hold and build and gain further ground. America must defeat the rising threat of domestic terrorism. It is real. It is here. And we must have a formidable approach to it," said Mayor Adams.
Lawmakers are looking into some sort of a national strategy to combat antisemitism, something both DHS and the FBI have voiced support of.
'You Can Always Rely on God': Former Miss Universe Says Faith Is Foundation of Relationship with NFL Star


text:
Home OICC
Oxford International Collaboration Centre
Oxford International Collaboration Centre (OICC) is a UK registered organisation and one of the AUO's subsidiaries bodies with an aim to facilitate the University's international collaboration with like-minded institutions. It also acts as the University's arm for commercialisation. The mission of OICC is to provide effective, efficient, and professional support to Azad University branches and other educational and corporate organisations to enhance their strategic and operational processes and fulfil their aspirations of becoming a world-class organisation.
The range of OICC services activities include, but not limited to, the following:
Designing, planning and delivery of executive training programmes for senior managers to meet objectives.
Developing and executing a variety of educational and corporate projects to enhance organisational quality and efficiency.
Organising seminars on topical subjects such as principal models for international collaborations.
Conducting short term research projects on a variety of international topics in social science, economy, technology or allied medical sciences.
Organising international conferences and forums in areas that most suit the client's objectives.
Supporting the academics of the member institutions in their international activities including participation in international conferences and publishing in international journals.
Providing information on the latest global developments in science, technology and higher education to member institutions.
Providing a platform to promote intercultural activities.
Major services of OICC are delivered through its Members Club. By becoming an OICC member, you will have exclusive access to a wide range of resources including specialised newsletter and priority project planning. For further information on how to join the OICC Members Club contact us on members@oicc.org.uk
Short courses starting soon in 2021
Executive Public Policy Course (EPPC)
E-Commerce in Light of International Trade Law
Discussing Islamic Art, Aesthetics, and Visuality
Architecture Certificate
Landscape Architecture Certificate


text:
Back to Developer Insights
Creating A Great Commerce Experience
Houzz's unique approach to monetization focuses on creating the best experience for homeowners and professionals through technology.
I'm Alon, Co-Founder of Houzz. My name is Guy.
I lead the mobile development at Houzz. When we got started, the best advice that we got was that we should focus first on the user experience and build that out until we really provide an amazing value to the community, and then monetization sort of follows organically at that point.
And that's what we did. So we spent the first few years really optimizing the experience, creating the best experience for homeowners and for the professionals. One of the things that are unique about the Houzz experience -- it's not a in-your-face shop.
It's something that lets the user learn and educate himself about design and design trends. At some point, you need to make a decision that you're going to, you know, turn on the ignition and start monetizing. We were very lucky in that regard.
We had great feedback from the community on what are the things that they wanted. So we followed those things and focused the monetization on solving those problems that the community had. So we created our local program. It's a local subscription program for home professionals -- architects, contractors, landscapers, et cetera. The second monetization channel that we started more recently is our marketplace. It's a commerce platform that lets homeowners find anything for their home, from sofas, to lighting, to vanities, et cetera. And that also came because we started getting phone calls to the office from homeowners that wanted to, oh, I just want to buy this sofa or this bathtub that I see in the picture. And we kept sending them to stores to buy it, but, really, no. We want to buy it on Houzz. Where is the Add to Cart button? So we created an Add to Cart button. We constantly monitor and talk to people who shop, both the ones who end up buying and the ones who don't, and try to get feedback from them. What worked? What didn't work well? A lot of people wanted to visualize what that product would look like in their room, and so we ended up creating the View in My Room feature, where you can take five million products and see what they look like in your home. People who use this feature end up buying a lot more.
The Houzz app helped grow the business by exposing us to a different user base and the website. Users on mobile are much more engaged, are much more returning to the app, and are much more dedicated to the Houzz experience. When we introduced Apple Pay, we also introduced a Quick Checkout feature that allows people basically to skip the card. You don't need to fill in your details because they're already pre-filled in with Apple Pay, and that's it. So basically, it really reduced the obstacle or the hurdle to converting a user to a buying user. Think about the experience that you bring to your users and give them a lot of reasons to return to your app.
After you do that, introducing e-commerce to the app is easy. I remember for many years reading stories about how other companies got started and trying to understand what is the secret sauce that goes into it. When you look at it from the outside, it always looks like magic.
What you don't see is all the hard work behind the scenes, all of the failures, all the things that didn't work as well. That's kind of the big magic, really, at the end of the day is when things don't work out the way you want it. You just continue to work on it until they do. Try to do things that are different.
Try to see exactly what is it that people need and fill the solution for what they need. And don't try to build something that, you know, you've seen others build already. Try to build it differently. Try to build it in the way that would really solve the problem that the users are having.
Developer Insights


155 Reviews and Price for LG 7.5 kg Semi Automatic Top Load Washing Machine(P8540R3FA) - ReadyViews !
The above analysis of LG 7.5 kg Semi Automatic Top Load Washing Machine(P8540R3FA) is done on the basis of 155 reviews collected from various stores across India.
The customer review score of LG 7.5 kg Semi Automatic Top Load Washing Machine(P8540R3FA) is 62 / 100.
The Price of LG 7.5 kg Semi Automatic Top Load Washing Machine(P8540R3FA) fluctuate regularly and the last price updated 1 year ago.
This product is available in 3 different colors - Dark Grey, Blue, Dark Blue .
The Best features of LG 7.5 kg Semi Automatic Top Load Washing Machine(P8540R3FA) are Power & Safety, Noise & Vibration, Drying.
For the latest updates of LG 7.5 kg Semi Automatic Top Load Washing Machine(P8540R3FA), Please visit ReadyViews regularly.


There are many amazing places around the globe and I ended up in Edinburgh. Yes city is historical and beautiful but sometimes I wonder if amount of rain and wind and darkness don´t beat this beautifulness. There is something about this place what is not easy to name it but is definitely special. Nowhere else I have ever lived or spent some time I have felt so shifted emotions as here. This is place of my highest and happiest self as darkest and lowest as well.
North Berwick. I heard so often how wonderful place it is and I have to go visit there. It´s been couple of years since I moved to Edinburgh and still haven´t got chance see this so called ´wonderful place´. Then they came visit me from distant country. They have seen quite a lot of Edinburgh even Scotland, so maybe it´s time to see something more around the place I live. Let´s go to North Berwick.


text:
You are viewing a javascript disabled version of the site. Please enable Javascript for this site to function properly.
Go to headerGo to navigationGo to searchGo to contentsGo to footer
In header section. Select this link to jump to navigation
In navigation section. Select this link to jump to content
title="Change currency to USD - US Dollar"$
Published between: Published from year: and Published to year: Search syntax help
Searching for just a few words should be enough to get started. If you need to make more complex queries, use the tips below to guide you.
This NOT that
Must include "This" and "That"
This That
Must not include "That"
This -That
"This" is optional
This +That
Exact phrase "This That"
"This That"
(this AND that) OR (that AND other)
In content section. Select this link to jump to navigation
Who's good this year? Comparing the information content of games in the four major US sports
Authors: Wolfson, Julian; * | Koopmeiners, Joseph S. | DiLernia, Andrew
Affiliations: Division of Biostatistics, University of Minnesota, Minneapolis, MN, USA
Correspondence: [*] Corresponding author: Andrew DiLernia, Division of Biostatistics, University of Minnesota, Minneapolis, MN, USA. E-mail: [email protected].
Keywords: Prediction, information, paired, comparison models, season length
DOI: 10.3233/JSA-170199
Journal: Journal of Sports Analytics, vol. 4, no. 2, pp. 153-163, 2018
In all four major North American professional sports (baseball, basketball, football, and hockey), the primary aim of the regular season is to identify the best teams. Yet the number of regular season games used to distinguish between the teams differs dramatically between the sports, ranging from 16 (football) to 82 (basketball and hockey) to 162 (baseball). While length of season is partially determined by factors including travel logistics, rest requirements, playoff structure and television contracts, from a statistical perspective the 10-fold difference in the number of games between leagues suggests that some league's games are more "informative" than others. In this paper, we propose a method to quantify the amount of information games yield about the relative strengths of the teams involved. Our strategy is to estimate a predictive accuracy curve which assesses how well simple paired comparison models fitted from X% of games within a season predict the outcomes of the remaining (100 - X)% of games, across multiple values of X. We compare predictive accuracy curves between seasons within each sport and across all sports, and find dramatic differences in the amount of information yielded by game results in the four major North American sports leagues.
In week 14 of the 2012 National Football League season, the New England Patriots squared off on Monday Night Football against the Houston Texans in a game with major implications for both teams. At the time, the Texans had the best record in the conference (11 wins versus 1 loss) and were in line to earn home-field advantage throughout the playoffs, while the New England Patriots (9 wins, 3 losses) had the best record in their division and were hoping to solidify their playoff position and establish themselves as conference favorites. The Patriots ultimately defeated the Texans 42-14, which led some commentators to conclude that the Patriots were the favorites to win the Super Bowl (Walker, 2012, MacMullan, 2012) and that Tom Brady was the favorite for the MVP award (Reiss, 2012). Others opined that the game provided evidence that the Texans were in reality less talented than they appeared over the first 13 weeks of the season (Kuharsky, 2012). These are strong conclusions to reach based on the results of a single game, but the power of such "statement games" is accepted wisdom in the NFL. In contrast, it is rare for the outcome of a single regular-season game to create or change the narrative about a team in the NBA, NHL, or MLB. While one might argue that the shorter NFL season simply drives commentators to imbue each game with greater metaphysical meaning, an alternative explanation is that the outcome of a single NFL contest actually does carry more information about the relative strengths of the teams involved than a single game result in the other major North American professional sports. In this paper, we ask and attempt to answer the basic question: how much does the outcome of a single game tell us about the relative strength of the two teamsinvolved?
In the four major North American professional sports (baseball, basketball, football, and hockey), the primary purpose of the regular season is to determine which teams most deserve to advance to the playoffs. Interestingly, while the ultimate goal of identifying the best teams is the same, the number of regular season games played differs dramatically between the sports, ranging from 16 (football) to 82 (basketball and hockey) to 162 (baseball). Though length of season is partially determined by many factors including travel logistics, rest requirements, playoff structure and television contracts, it is hard to reconcile the 10-fold difference in the number of games in the NFL and MLB seasons unless games in the former are somehow more informative about team abilities than games in the latter. Indeed, while it would be near-heresy to determine playoff eligibility based on 16 games of an MLB season (even if each of the 16 games was against a different opponent), this number of games is considered adequate for the same purpose in the NFL.
There is a well-developed literature on the topic of competitive balance and parity in sports leagues (Owen, 2010; Horowitz, 1997; Mizak et al., 2005; Lee, 2010; Hamlen, 2007; Cain and Haddock, 2006; Larsen et al., 2006; Ben-Naim et al., 2006; Késenne, 2000; Vrooman, 1995; Koopmeiners, 2012). However, most papers focus on quantifying the degree of team parity over consecutive years along with the effects of measures taken to increase or decrease it. In papers which compare multiple sports, season length is often viewed as a nuisance parameter to be adjusted for rather than a focus of inquiry. As a result, little attention has been directed at the question of how information on relative team strength accrues over the course of a single season.
In this paper, we aim to quantify the amount of information each game yields about the relative strength of the teams involved. We estimate team strength via paired-comparison (Bradley and Terry, 1952) and margin-of-victory models which have been applied to ranking teams in a variety of sports (McHale and Morton, 2011; Koehler and Ridpath, 1982; Sire and Redner, 2009; Martin, 1999). The growth in information about the relative strength of teams is quantified via a predictive accuracy curve which describes how paired-comparison models fitted from X% of the games in a season predict the outcomes of the remaining (100 - X)% of games, across multiple values of X (games are partitioned into training and test sets at random to reduce the impact of longitudinal trends over the course of a season). A predictive accuracy curve is also obtained for describing how paired-comparison models fitted from X number of games from a season predict the outcomes of the remaining games in the season, across multiple values of X. We begin by describing the data and analysis methods we used in Section 2. Section 3 presents results from recent seasons of the four major North American sports, and compares the "information content" of games across the four sports. In Section 4 we discuss the strengths and limitations of our analysis.
2Methods
2.1Data
We consider game results (home and away score) for the 2010-2015 seasons for the NFL, the 2010-2011 to 2015-2016 seasons of the NBA, the 2010-2011 to 2015-2016 seasons of the NHL, and the 2010-2015 seasons of MLB. Game results for the NFL, NBA and NHL were downloaded from Sports-Reference.com (Drinen, 2014) and game results for MLB were downloaded from Retrosheet (Smith, 2014). Only regular season games were considered in our analysis. A small number of tie games were removed from the data to simplify the fitting of models for binary win/loss outcomes, though we note that there are models that can accommodate tied game results (Rao and Kupper, 1967).
2.2Quantifying Informativeness
Let G represent the outcomes (either a win/loss indicator or margin of victory) from all the games within a single season of a sport. Our goal is to quantify the amount of information on relative team strength contained in a set of games G⊂G , as the proportion of the total number of games in the set varies. We consider two types of paired comparison models in our work. Each game g ∈ G provides information on the home team (Hg = i), away team (Ag = j) and the game result as viewed from the home team's perspective. Let the binary win/loss game result Wg = 1 if the home team wins the game, otherwise Wg = 0, and let πi,j = P (Wg = 1), i.e., the probability that the home team, team i, defeats the visiting team, team j in game g. We fit a logistic regression model which is equivalent (see Agresti (2002)) to the standard Bradley-Terry model (Bradley and Terry, 1952):
logit(πi,j)=βi-βj+α,
The βi and βj terms are the team strength parameters for teams i and j, respectively, and α is a home-field advantage parameter.
We fit a similar model when the actual game scores are considered. In this context, home team margin of victory (MOV) Δg is recorded for each game; Δg is positive for a home team win and negative for a home team loss (as noted above, a small number of tie games with Δg = 0 were excluded from our analyses). The paired comparison model incorporating margin of victory is:
μi,j=δi-δj+λ,
where μi,j = E (Δg) is the expected margin of victory for the home team, team i, over the visiting team, team j. δi and δj are team strengths on the margin-of-victory scale for teams i and j, respectively, and λ is a home-field advantage on the margin-of-victory scale.
Both models (1) and (2) can be fit using standard statistical software, such as R (R Core Team, 2013). Given estimates βˆi , βˆj , and αˆ derived by fitting model (1) to a set of games G, a predicted home team win probability πˆg can be derived for every game g∈G′≡G∖G based on which teams i and j are involved. A binary win/loss prediction for the home team is obtained according to whether πˆg is greater/less than 0.5. Given estimates δˆi , δˆj , and λˆ from fitting model (2), home team margin of victory μˆg can similarly be predicted for every game in g ∈ G′. A binary win/loss prediction for the home team is obtained according to whether μˆg is positive or negative.
Our metrics for summarizing the amount of information on relative team strength are based on how well the results of games in G allow us to predict the outcomes of games in G′. Specifically, given G and G′, our information metric is the fraction of games in G′ which are correctly predicted using a paired comparison model applied to G:
IBT(G,G′)=∑g∈G′Wg𝟙[πˆg>0.5]|G′|fortheBradley-Terrymodel(1)IMOV(G,G′)=∑g∈G′Wg𝟙[μˆg>0]|G′|forthemargin-of-victorymodel(2)
where πˆg and μˆg are estimates derived from game results in G, and |G′| denotes the number of games in G′. The BT and MOV superscripts denote the Bradley-Terry (i.e., win-loss) and margin of victory models respectively.
For a given season, we estimated IBT and IMOV for sets of game results corresponding to 12.5%, 25.0%, 37.5%, 50.0%, 62.5%, 75.0% and 87.5% of the games in each available season. For a given season percentage X%, training data sets G1, G2, …, GK were formed by randomly sampling games corresponding to X% of that season, and test data sets G1′,G2′,…,GK′ were created as the within-season complements of the training sets. That is, if Gk consists of a number of games corresponding to X% of the season, then Gk′ contains the remaining (100-X)% of games in that season. Games were sampled at random so as to reduce the influence of temporal trends in team strength over the course of a season. For example, baseball teams who are out of playoff contention often trade away valuable players and give playing time to minor league prospects in August and September, so that team strength at the end of the season may be quite different than at the beginning. The full algorithm appearsbelow.
1. For X = 12.5, 25, 37.5, 50, 62.5, 75, and 87.5:
(a) Generate 100 training sets G1, G2, …, G100 (and complementary test sets G1′,G2′,…,G100′ ) by randomly sampling X% of games without replacementfrom G .
(b) For each training set Gk:
i. Fit models (1) and (2) to the games in Gk.
ii. Obtain binary win/loss predictions for the games in the test set Gk′ .
iii. Evaluate the information metrics IBT(Gk,Gk′) and IMOV(Gk,Gk′)
(c) Average the computed information metrics to estimate the predictive accuracy of paired comparison models fitted to data from X% of the entire season (IBT and IMOV).
2. Summarize IBT and IMOV across different values of X.
The above approach defines a predictive accuracy curve which quantifies how the ability to predict game outcomes changes as a higher proportion of the season's games are used in a predictive model. Through a similar process, we produced a predictive accuracy curve which quantifies how the ability to predict game outcomes changes as a higher number of games from the season are used in the model.
2.3Information accrual rate
In addition to quantifying the accuracy of prediction models, we also sought to measure how quickly information accrued in each sport, i.e., how rapidly prediction accuracy improved as the number of games used to fit the prediction model increased. We therefore calculated a sport-specific information accrual rate based on the derivative of the IMOV curve. Specifically, we calculated the information accrual rate as follows:
1 Fit a fourth-degree (quartic) polynomial equation, via least squares, to the sport-specific values of IMOV for all years since 2010.
2 Compute the derivative of the fitted curves (a trivial task since the curve is defined by a polynomial) to define an instantaneous information accrual rate, i.e., the rate of change in IMOV for a prediction model using any given number of games or fraction of games in the season.
For the sake of brevity, we present information accrual rates for IMOV only; the same steps could easily be applied to compute information accrual on the basis of IBT. The fitted quartic polynomial curves and information accrual rate curves for the four sports are presented in Section 3. Model coefficients and their corresponding standard error estimates are provided in Tables A1 through A4 in Appendix A.
Figures 1 through 4 summarize the trajectories of IBT and IMOV for multiple seasons in each of the four major U.S. sports. The natural null model comparison for these curves is the "home-field advantage" (HFA) model which chooses the home team to win every game; in these plots, the predictive accuracy of the HFA model is represented by a horizontal solid line. The average win probability for the home team (as determined by the parameters α and λ in models (1) and (2) respectively) varies from approximately 53% to 61% across the four sports. The home team winning between 55% and 60% of NFL games, approximately 60% of NBA games, and between 50% and 55% of MLB and NHL games is consistent with previous studies of home-field advantage (Pollard and Pollard, 2005; Liardi and Carron, 2011).
Percent of games correctly predicted on test set vs. average number of games per team in training set, NFL seasons 2010-2015.
3.1National Football League
The percent of games correctly predicted on the test set versus the average number of games per team in the training set for the 2010-2015 National Football League seasons is displayed in Fig. 1. Both paired comparison models (i.e., those which incorporate and ignore margin of victory) outperform simply picking the home team to win every game. The margin of victory model appears to perform slightly better than the paired comparison model, though the differences are modest (and in the 2014 season, non-existent). The prediction accuracy of both models improves as the number of games used to make predictions increases, with the rate of increase in accuracy (i.e., information) being largest for the first 4-6 games per team included in the model. While the rate of increase in accuracy slows as additional games are added to the prediction model, it is notable that accuracy continues to increase even beyond 10-12 games in most years.
3.2National Basketball Association
Results for the National Basketball Association can be found in Fig. 2. The NBA was the most predictable of the four major North American professional sports leagues. Using 87.5% of games as a training set, our model was able to predict with over 65% accuracy across seasons. The NBA also had the largest home court advantage with home teams winning approximately 60% of games. There was virtually no advantage in including margin of victory in our models. The only major difference between the NFL and NBA was the growth of information over the season. While the accuracy of our predictions for the NFL continued to improve as more games were added to the training set, model accuracy for the NBA did not improve substantially once more than 25% of games (i.e., ≥ 21 games per team) were included in the training set. Analyses using the segmented package in R for fitting piecewise linear models (Muggeo, 2003, 2008) confirmed an inflection point in the prediction accuracy curve when approximately 25-30 games per team were used in the model.
Percent of games correctly predicted on test set vs. average number of games per team in training set, NBA seasons 2011-2016.
3.3Major League Baseball and the National Hockey League
Results from Major League Baseball and the National Hockey League are found in Figs. 3 and 4, respectively. The results for MLB and the NHL were quite similar, in that both leagues were substantially less predictable than the NFL and NBA. The percentage of games correctly predicted for MLB never exceeded 58% even when 140 games (87.5% of a season) were included in the training set. The NHL was slightly better but our model was never able to predict more than 59% of games correctly. Prediction accuracy was rarely more than 2-3 percentage points better than the simple strategy of picking the home team in every game for either league. For example, the maximum predictive accuracy in the NHL was achieved in the 2012-2013 season when the home team win probability was relatively high at 57%. And, during the 2011-2012 season, picking the home team performed better than paired comparison models constructed using a half-season's worth of game results.
Percent of games correctly predicted on test set vs. average number of games per team in training set, MLB seasons 2010-2015.
Percent of games correctly predicted on test set vs. average number of games per team in training set, NHL seasons 2011-2016.
3.4Comparing the sports
Here, we summarize and compare the predictive accuracy of the MOV model for the four major sports, aggregated across the years of available data. Results from the win-loss model were similar, and are not shown. Figure 5a is an aggregated version of the per-sport predictive accuracy plots, and summarizes predictive accuracy versus the number of games used in the training set. Figure 5b also plots predictive accuracy, but versus the proportion of games used in the training set. Information accrual rates (see Section 2.3) are summarized, per game and per proportion of games, in Figs 6a and 6b.
Proportion of games correctly predicted by margin of victory model (IMOV) for four major U.S. sports leagues. Lines are quartic polynomials fit to data from each sport aggregated across the years 2010-2016. (a) Information accrual rate by number of games used in prediction model. Number of games truncated at 41 for readability. (b) Information accrual rate by proportion of season games used in prediction model.
Information accrual rate (first derivative of IMOV curve) for four major U.S. sports leagues. (a) Information accrual rate by number of games used in prediction model. Number of games truncated at 41 for readability. (b) Information accrual rate by proportion of season games used in prediction model.
Figures 5a and 6a show that on a per-game basis, NFL games are most informative. Over the first five games (per team) used in the prediction model, prediction accuracy improves by at least 1% per game, with the most dramatic improvements (3-4% per game improvement rate) accruing after the initial 2-3 games. The initial 5-10 games of the NBA season offer more modest, but still substantial,improvements of approximately 1% accuracy per game. Initial NHL games are slightly more informative than initial MLB games, but the per-game improvements in predictive accuracy are below 0.5% and 0.2% respectively.
Figures 5b and 6b place data on the same horizontal scale, comparing predictive accuracy and information accrual rate as the proportion of games used in the prediction model varies. From Figure 6b, we see that the first 10-15% of games included in the NBA prediction model actually provide more information than the first 10-15% of games included in the NFL prediction model. However, the information accrual rate of NBA games quickly approaches zero beyond this point, while prediction model accuracy continues to improve in the NFL model beyond 50% of games. Indeed, at the point where 25% of games have been included in the prediction model, the information accrual rate of the NBA is very similar to that of the MLB and NHL (∼0.1%), while the NFL's information accrual rate is more than 2.5 times higher (∼0.25%). Information accrues at a more modest rate for MLB and NHL games; for these two sports, as in the NBA, the accrual rate is essentially zero once 30% of the season's games are included in the prediction model.
4Discussion
Our results reveal substantial differences between the major North American sports according to how well one is able to discern team strengths (and hence predict the outcomes of future games) using game results from a single season. NBA games are most easily predicted, with paired comparison models having good predictive accuracy even including a small fraction of the season; indeed, since our information metric for the NBA appears to plateau at around 25 games, a large fraction of games in the NBA season are superfluous from the point of view of distinguishing the best and worst teams in the league. NFL game results also give useful information for determining relative team strength. On a per-game basis, NFL contests contain the largest amount of information, and unlike in the other sports substantial information continues to accrue though the majority of the season's games. While we randomly permuted the order of games when adding them to our prediction model instead of considering them in their scheduled order, our results suggest that for the NBA, NHL, and MLB, the first quarter of the season provides most of the information necessary for determining relative team strength, while games in the second half of the NFL season contribute useful information in determining the strongest teams.
The predictive ability of paired comparison models constructed from MLB and NHL game data remains limited even when results from a large number of games are used. One interpretation of this finding is that, in comparison to the NBA and NFL, games in MLB and the NHL carry little information about relative team strength. Our results may also reflect smaller variance in team strengths (i.e., greater parity) in hockey and baseball: Because our information metric considers the predictive accuracy averaged across all games in the test set, if most games are played between opposing teams of roughly the same strength then predictive models based only on paired comparisons will fare poorly. Indeed, the inter-quartile range for winning percentage in these sports is typically on the order of ∼20%, while in football and basketball it is closer to 30%.
Our observation that the hockey and baseball regular seasons do relatively little to distinguish between teams' abilities is reflected in playoff results in these sports, where "upsets" of top-seeded teams by teams who barely qualified for the postseason happen much more regularly than in the NFL and NBA. Specifically, for the six seasons of available data lower-seeded teams won first-round playoff series 43.8% of the time in the NHL, and 58.3% of the time in MLB (Drinen, 2014, Smith, 2014). However, lower-seeded teams won only 25.0% of divisional round playoff games in the NFL, and 27.1% of first-round games in the NBA. While there are many considerations when designing playoff structures (Bojke, 2008), an argument could be made for increasing the number of teams that qualify for the MLB playoffs since the current 10-team format is likely to exclude teams of equal or greater ability than ones that make it. Using similar logic, one might also argue that perhaps the NBA playoffs are overly inclusive as there is ample information contained in regular season game outcomes to distinguish between the best teams and those that are merely average.
The enormous discrepancy in the informativeness of game results between hockey and basketball, which both currently play seasons of the same length, is notable. One possible explanation for why basketball game results more reliably reflect team strength is that a large number of baskets are scored, and the Law of Large Numbers dictates that each team approaches their "true" ability level more closely. In contrast, NHL games are typically low-scoring affairs, further compounded by the fact that a large fraction of goals are scored on broken plays and deflections which seem to be strongly influenced by chance. We have not analyzed data from soccer, but it would be interesting to explore whether the "uninformativeness" of hockey and baseball game results extends to other sports, or whether the relatively low parity of soccer makes individual games more "informative" according to our metrics.
Our analysis has several limitations. First, we chose to quantify information via the predictive accuracy of simple paired comparison models. It is possible that using more sophisticated models for prediction might change our conclusions, particularly for sports like the NBA where the predictiveness curve plateaus early. Nevertheless, we doubt that using more complex models would erase the sizable between-sport differences that we observed. One possible explanation for the fact that the outcome of a randomly chosen baseball game is hard to predict based on previous game results is the significant role that the starting pitcher plays in determining the likelihood of winning; the "effective season length" of MLB could be viewed as being far less than 162 games because each team-pitcher pair carries a different win probability. However, in additional analyses (results not shown), we fitted paired comparison models including a starting pitcher effect and this did not substantially affect our results. Second, it could be argued that team win probabilities change over the course of a season due to roster turnover, injuries, and other effects. By randomly assigning games to our training and test set without regard to their temporal ordering, we are implicitly estimating "average" team strengths over the season, and applying these to predict the outcome of an "average" game. We chose a random sampling approach over one which would simply split the season because we wanted to eliminate time trends in team strengths when describing how information accrued as more game results were used to build prediction models. Our approach therefore does not directly describe how predictive accuracy improves as games are played in their scheduled order.
Table A1
Fitted coefficients for the quartic polynomial model E(IgMOV)=β0+β1g+ β2g2 + β3g3 + β4g4, where IgMOV is the proportion of games correctly predicted by a MOV model trained on g game results. The functions are plotted in Fig. 5a.
League β0 β1 β2 β3 β4
MLB 0.505 0.002 –3.07E-05 2.46E-07 –7.04E-10
NBA 0.537 0.016 –6.25E-04 1.03E-05 –5.91E-08
NFL 0.454 0.065 –9.16E-03 6.26E-04 –1.61E-05
NHL 0.504 0.004 –1.40E-04 2.07E-06 –1.11E-08
Fitted coefficients for the quartic polynomial model E(IpMOV)=β0+β1p+β2p2+β3p3+β4p4 , where IpMOV is the proportion of games correctly predicted by a MOV model trained on game results representing a proportion p of the season. The functions are plotted in Fig. 5b.
MLB 0.50 0.29 –0.83 1.09 –0.51
NBA 0.54 1.33 –4.37 5.95 –2.81
NFL 0.45 1.04 –2.35 2.56 –1.06
NHL 0.50 0.37 –1.01 1.25 –0.56
Standard error estimates for coefficients of quartic polynomial model E(IgMOV)=β0+β1g+β2g2+β3g3+β4g4 , where IgMOV is the proportion of games correctly predicted by a MOV model trained on g game results. The functions are plotted in Fig. 5a.
MLB 2.71E-03 3.69E-04 1.14E-05 1.23E-07 4.30E-10
NBA 4.67E-03 9.56E-04 5.63E-05 1.20E-06 8.28E-09
NFL 3.10E-02 2.28E-02 5.30E-03 4.83E-04 1.50E-05
NHL 5.22E-03 1.07E-03 6.29E-05 1.34E-06 9.25E-09
Standard error estimates for coefficients of quartic polynomial model E(IpMOV)=β0+β1p+β2p2+β3p3+β4p4 , where IpMOV is the proportion of games correctly predicted by a MOV model trained on game results representing a proportion p of the season. The functions are plotted in Fig. 5b.
MLB 0.003 0.060 0.300 0.528 0.299
NBA 0.005 0.078 0.375 0.660 0.375
NFL 0.031 0.365 1.357 1.978 0.985
NHL 0.005 0.088 0.427 0.751 0.427
Agresti A. , 2002, Categorical Data Analysis, Wiley series inprobability and statistics, 2 edn, John Wiley & Sons.
Ben-Naim E. , Vazquez F. & Redner S. , 2006, Parity and predictability of competitions, Quantitative Analysis in Sports, 2(4), 1–12.
Bojke C. , 2008, The impact of post-season play-off systems on theattendance at regular season games, in Albert J. and Koning R. H. ,eds, 'Statistical Thinking in Sports', Chapman & Hall/CRC Press, Boca Raton, FL, chapter 11, pp. 179–202.
Bradley R.A. and Terry M.E. , 1952, Rank analysis of incomplete block designs: I. The method of paired comparisons, Biometrika. 324–345. http://www.jstor.org/stable/2334029
Cain L.P. and Haddock D.D. , 2006, Research notes: Measuring parity tying into the idealized standard deviation, Journal of Sports Economics, 7(3), 330–338. http://jse.sagepub.com/content/7/3/330.short
Drinen D. , 2014, Pro-football-reference.com - pro football statistics and history. http://www.pro-football-reference.com
Hamlen W.A. , 2007, Deviations from equity and parity in the National Football League, Journal of Sports Economics, 8(6), 596–615. http://jse.sagepub.com/content/8/6/596.short
Horowitz I. , 1997, The increasing competitive balance in Major League Baseball, Review of Industrial Organization, 12(3), 373–387. http://link.springer.com/article/10.1023/A:1007799730191
Késenne S. , 2000, Revenue sharing and competitive balance in professional team sports, Journal of Sports Economics, 1(1), 56–65. http://jse.sagepub.com/content/1/1/56.short
Koehler K.J. and Ridpath H. , 1982, An application of a biased version of the Bradley-Terry-Luce model to professional basketball results, Journal of Mathematical Psychology, 25(3), 187–205.
Koopmeiners J.S. , 2012, Comparing the autocorrelation and variance of NFL team strengths over time using a Bayesian state-space model, Journal of Quantitative Analysis in Sports, 8(3), Article 2.
Kuharsky P. , 2012, 'Texans get a lesson in "what it takes". http://espn.go.com/blog/afcsouth/post//id/44713/texans-get-a-lessonin-what-it-takes
Larsen A. , Fenn A.J. and Spenner E.L. , 2006, The impact of free agency and the salary cap on competitive balance in the National Football League, Journal of Sports Economics, 7(4), 374–390. http://jse.sagepub.com/content/7/4/374.short
Lee T. , 2010, Competitive balance in the national football league after the 1993 collective bargaining agreement, Journal of Sports Economics, 11(1), 77–84. http://jse.sagepub.com/content/7/4/374.short
Liardi V. and Carron A. , 2011, An analysis of National Hockey League faceoffs: Implications for the home advantage, International Journal of Sport and Exercise Psychology, 9(2), 102–109.
MacMullan J. , 2012, 'Patriots' defense comes of age'. http://espn.go.com/boston/nfl/story//id/8735498/new-england-patriotsdefense-comes-age-counts
Martin D.E.K. , 1999, Paired comparison models applied to the design of the Major League baseball play-offs, Journal of Applied Statistics, 26(1), 69–80.
McHale I. and Morton A. , 2011, A Bradley-Terry type model for forecasting tennis match results, International Journal of Forecasting, 27(2), 619–630.
Mizak D. , Stair A. and Rossi A. , 2005, Assessing alternative competitive balance measures for sports leagues: a theoretical examination of standard deviations, gini coefficients, the index of dissimilarity, Economics Bulletin, 12(5), 1–11. http://www.accessecon.com/pubs/EB/2005/Volume12/EB-04L80002A.pdf
Muggeo V.M. , 2003, Estimating regression models with unknown breakpoints, Statistics in Medicine, 22, 3055–3071.
Muggeo V.M.R. , 2008, Segmented: an r package to fit regression models with broken-line relationships, R News, 8(1), 20–25. http://cran.r-project.org/doc/Rnews/
Owen P.D. , 2010, Limitations of the relative standard deviation ofwin percentages for measuring competitive balance in sports leagues, Economics Letters, 109(1), 38–38. http://www.sciencedirect.com/science/article/pii/S0165176510002648
Pollard R. and Pollard G. , Long-term trends in home advantage in professional team sports in North America and England, Journal of Sports Sciences, 23(4), 337–350.
R Core Team., R. 2013, A Language and Environment for Statistical Computing, R Foundation for Statistical Computing, Vienna, Austria. http://www.R-project.org/.
Rao P.V. and Kupper L.L. , 1967, Ties in paired-comparison experiments: A generalization of the Bradley-Terry model, Journal of the American Statistical Association, 62(317), 194–204.
Reiss M. , 2012, Tom Brady shows MVP chops. http://espn.go.com/boston/nfl/story//id/8735476/tom-brady-looks-mvpworthy-romp-houston-texans
Sire C. & Redner S. , 2009, Understanding baseball team standings and streaks, The European Physical Journal B, 67(3), 473–481.
Smith D. , 2014, Retrosheet.org. http://retrosheet.org
Vrooman J. , 1995, A general theory of professional sports leagues, Southern Economic Journal. 971–990. http://www.jstor.org/stable/1060735
Walker J. , 2012, Patriots are the new Super Bowl favorites. http://espn.go.com/blog/afceast/post//id/52084/patriots-are-the-newsuper-bowl-favorites
Linked in share
Volume Pre-press
Issue Pre-press
Go to headerGo to navigationGo to searchGo to contentsGo to footer In footer section. Select this link to jump to content
Administrator log in
Copyright ©2022 IOS Press All rights reserved.
Join our network:
IOS Press, Inc.
6751 Tepper Drive
Clifton, VA 20124
For editorial issues, like the status of your submitted paper or proposals, write to [email protected]
For editorial issues, permissions, book requests, submissions and proceedings, contact the Amsterdam office [email protected]
Inspirees International (China Office)
Ciyunsi Beili 207(CapitaLand), Bld 1, 7-901
Free service line: 400 661 8717
如果您在出版方面需要帮助或有任何建, 件至: [email protected]
Built on the Scolaris platform by:


text:
package com.intel.analytics.bigdl.friesian

import com.intel.analytics.bigdl.dllib.NNContext
import com.intel.analytics.bigdl.friesian.python.PythonFriesian
import org.apache.logging.log4j.Level
import org.apache.logging.log4j.core.config.Configurator
import org.apache.spark.rdd.RDD
import org.apache.spark.sql.functions._
import org.apache.spark.sql.types._
import org.apache.spark.sql.{Row, SQLContext}
import org.apache.spark.{SparkConf, SparkContext, SparkException}

import java.net.URL
import scala.collection.JavaConverters._
import scala.collection.mutable

class FriesianSpec extends ZooSpecHelper {
  var sqlContext: SQLContext = _
  var sc: SparkContext = _
  val resource: URL = getClass.getClassLoader.getResource("")
  val friesian = PythonFriesian.ofFloat()

  override def doBefore(): Unit = {
    Configurator.setLevel("org", Level.ERROR)
    val conf = new SparkConf().setMaster("local[1]").setAppName("FriesianTest")
    sc = NNContext.initNNContext(conf)
    sqlContext = SQLContext.getOrCreate(sc)
  }

  override def doAfter(): Unit = {
    if (sc != null) {
      sc.stop()
    }
  }

  "Fill NA int" should "work properly" in {
    val path = resource.getFile + "/data1.parquet"
    val df = sqlContext.read.parquet(path)
    val cols = Array("col_1", "col_2")
    val dfFilled = friesian.fillNa(df, 0, cols.toList.asJava)
    TestUtils.conditionFailTest(dfFilled.filter(dfFilled("col_1").isNull).count == 0)
    TestUtils.conditionFailTest(dfFilled.filter(dfFilled("col_2").isNull).count == 0)
  }

  "Fill NA string" should "work properly" in {
    val path = resource.getFile + "/data1.parquet"
    val df = sqlContext.read.parquet(path)
    val cols = Array("col_4", "col_5")
    val dfFilled = friesian.fillNa(df, "bb", cols.toList.asJava)
    TestUtils.conditionFailTest(dfFilled.filter(dfFilled("col_4").isNull).count == 0)
    TestUtils.conditionFailTest(dfFilled.filter(dfFilled("col_5").isNull).count == 0)
  }

  "Fill NA string int" should "throw exception" in {
    val path = resource.getFile + "/data1.parquet"
    val df = sqlContext.read.parquet(path)
    val cols = Array("col_1", "col_4")
    assertThrows[IllegalArgumentException] {
      friesian.fillNa(df, "bb", cols.toList.asJava)
    }
  }

  "Fill NAInt" should "work properly" in {
    val path = resource.getFile + "/data1.parquet"
    val df = sqlContext.read.parquet(path)
    val dfFilled = friesian.fillNaInt(df, 3)
    TestUtils.conditionFailTest(dfFilled.filter(dfFilled("col_2").isNull).count == 0)
    TestUtils.conditionFailTest(dfFilled.filter(dfFilled("col_3").isNull).count == 0)
    val dfFilled2 = friesian.fillNaInt(df, 4, List("col_3").asJava)
    TestUtils.conditionFailTest(dfFilled2.filter(dfFilled2("col_2").isNull).count == 1)
    TestUtils.conditionFailTest(dfFilled2.filter(dfFilled2("col_3").isNull).count == 0)
  }

  "Clip" should "work properly" in {
    val path = resource.getFile + "/data1.parquet"
    val df = sqlContext.read.parquet(path)
    val cols = Array("col_2", "col_3")
    val dfClip = friesian.clip(df, cols.toList.asJava, 1, 2)
    dfClip.show()
  }

  "mask Int" should "work properly" in {
    val data = sc.parallelize(Seq(
      Row("jack", Seq(1, 2, 3, 4, 5)),
      Row("alice", Seq(4, 5, 6, 7, 8)),
      Row("rose", Seq(1, 2))))
    val schema = StructType(Array(
      StructField("name", StringType, true),
      StructField("history", ArrayType(IntegerType), true)
    ))
    val df = sqlContext.createDataFrame(data, schema)
    val dfmasked = friesian.mask(df, Array("history").toList.asJava, 4)
    TestUtils.conditionFailTest(dfmasked.columns.contains("history_mask"))
    TestUtils.conditionFailTest(dfmasked.filter("size(history_mask) = 4").count() == 3)
    TestUtils.conditionFailTest(dfmasked.filter("size(history_mask) = 2").count() == 0)
  }

  "mask Long" should "work properly" in {
    val data = sc.parallelize(Seq(
      Row("jack", Seq(1L, 2L, 3L, 4L, 5L)),
      Row("alice", Seq(4L, 5L, 6L, 7L, 8L)),
      Row("rose", Seq(1L, 2L))))
    val schema = StructType(Array(
      StructField("name", StringType, true),
      StructField("history", ArrayType(LongType), true)
    ))
    val df = sqlContext.createDataFrame(data, schema)
    val dfmasked = friesian.mask(df, Array("history").toList.asJava, 4)
    TestUtils.conditionFailTest(dfmasked.columns.contains("history_mask"))
    TestUtils.conditionFailTest(dfmasked.filter("size(history_mask) = 4").count() == 3)
    TestUtils.conditionFailTest(dfmasked.filter("size(history_mask) = 2").count() == 0)
  }

  "mask Double" should "work properly" in {
    val data: RDD[Row] = sc.parallelize(Seq(
      Row("jack", Seq(1.0, 2.0, 3.0, 4.0, 5.0)),
      Row("alice", Seq(4.0, 5.0, 6.0, 7.0, 8.0)),
      Row("rose", Seq(1.0, 2.0))))
    val schema = StructType(Array(
      StructField("name", StringType, true),
      StructField("history", ArrayType(DoubleType), true)
    ))
    val df = sqlContext.createDataFrame(data, schema)
    df.show(100, false)
    df.printSchema()
    val dfmasked = friesian.mask(df, Array("history").toList.asJava, 4)
    dfmasked.show(100, false)

    TestUtils.conditionFailTest(dfmasked.columns.contains("history_mask"))
    TestUtils.conditionFailTest(dfmasked.filter("size(history_mask) = 4").count() == 3)
    TestUtils.conditionFailTest(dfmasked.filter("size(history_mask) = 2").count() == 0)
  }

  "mask Long and Int" should "work properly" in {
    val data = sc.parallelize(Seq(
      Row("jack", Seq(1, 2, 3, 4, 5), Seq(1L, 2L, 3L, 4L, 5L)),
      Row("alice", Seq(4, 5, 6, 7, 8), Seq(4L, 5L, 6L, 7L, 8L)),
      Row("rose", Seq(1, 2), Seq(1L, 2L))))
    val schema = StructType(Array(
      StructField("name", StringType, true),
      StructField("history", ArrayType(IntegerType), true),
      StructField("history1", ArrayType(LongType), true)
    ))
    val df = sqlContext.createDataFrame(data, schema)
    val dfmasked = friesian.mask(df, Array("history", "history1").toList.asJava, 4)
    TestUtils.conditionFailTest(dfmasked.columns.contains("history_mask"))
    TestUtils.conditionFailTest(dfmasked.columns.contains("history1_mask"))
    TestUtils.conditionFailTest(dfmasked.filter("size(history_mask) = 4").count() == 3)
    TestUtils.conditionFailTest(dfmasked.filter("size(history_mask) = 2").count() == 0)
    TestUtils.conditionFailTest(dfmasked.filter("size(history1_mask) = 4").count() == 3)
    TestUtils.conditionFailTest(dfmasked.filter("size(history1_mask) = 2").count() == 0)
  }

  "postpad Int" should "work properly" in {
    val data = sc.parallelize(Seq(
      Row("jack", Seq(1, 2, 3, 4, 5), Seq(Seq(1, 2, 3), Seq(1, 2, 3))),
      Row("alice", Seq(4, 5, 6, 7, 8), Seq(Seq(1, 2, 3), Seq(1, 2, 3))),
      Row("rose", Seq(1, 2), Seq(Seq(1, 2, 3), Seq(1, 2, 3)))))
    val schema = StructType(Array(
      StructField("name", StringType, true),
      StructField("history", ArrayType(IntegerType), true),
      StructField("history_list", ArrayType(ArrayType(IntegerType)), true)
    ))
    val df = sqlContext.createDataFrame(data, schema)
    val dft = friesian.postPad(df, Array("history", "history_list").toList.asJava, 4)
    dft.schema.fields.map(x => x.dataType).foreach(println(_))

    TestUtils.conditionFailTest(dft.filter("size(history) = 4").count() == 3)
    TestUtils.conditionFailTest(dft.filter("size(history_list) = 4").count() == 3)
    TestUtils.conditionFailTest(
      dft.filter(dft("name") === "rose").select("history").collect()(0)(0).toString()
        == "WrappedArray(1, 2, 0, 0)")
  }

  "postpad Double" should "work properly" in {
    val data = sc.parallelize(Seq(
      Row("jack", Seq(1.0, 2.0, 3.0, 4.0, 5.0), Seq(Seq(1.0, 2.0, 3.0), Seq(1.0, 2.0, 3.0))),
      Row("alice", Seq(4.0, 5.0, 6.0, 7.0, 8.0), Seq(Seq(1.0, 2.0, 3.0), Seq(1.0, 2.0, 3.0))),
      Row("rose", Seq(1.0, 2.0), Seq(Seq(1.0, 2.0, 3.0), Seq(1.0, 2.0, 3.0)))))
    val schema = StructType(Array(
      StructField("name", StringType, true),
      StructField("history", ArrayType(DoubleType), true),
      StructField("history_list", ArrayType(ArrayType(DoubleType)), true)
    ))
    val df = sqlContext.createDataFrame(data, schema)
    assertThrows[SparkException] {
      val df2 = friesian.postPad(df, Array("history", "history_list").toList.asJava,
        4, "5.6")
      df2.show(3, false)
    }
    val dft = friesian.postPad(df, Array("history", "history_list").toList.asJava, 4, 6.5)
    dft.schema.fields.map(x => x.dataType).foreach(println(_))

    TestUtils.conditionFailTest(dft.filter("size(history) = 4").count() == 3)
    TestUtils.conditionFailTest(dft.filter("size(history_list) = 4").count() == 3)
    TestUtils.conditionFailTest(
      dft.filter(dft("name") === "rose").select("history").collect()(0)(0).toString()
        == "WrappedArray(1.0, 2.0, 6.5, 6.5)")
  }

  "postpad Long" should "work properly" in {
    val data = sc.parallelize(Seq(
      Row("jack", Seq(1L, 2L, 3L, 4L, 5L), Seq(Seq(1L, 2L, 3L), Seq(1L, 2L, 3L))),
      Row("alice", Seq(4L, 5L, 6L, 7L, 8L), Seq(Seq(1L, 2L, 3L), Seq(1L, 2L, 3L))),
      Row("rose", Seq(1L, 2L), Seq(Seq(1L, 2L, 3L), Seq(1L, 2L, 3L)))))
    val schema = StructType(Array(
      StructField("name", StringType, true),
      StructField("history", ArrayType(LongType), true),
      StructField("history_list", ArrayType(ArrayType(LongType)), true)
    ))
    val df = sqlContext.createDataFrame(data, schema)
    val dft = friesian.postPad(df, Array("history", "history_list").toList.asJava, 4, 5.6)
    dft.show(3, false)
    //    dft.schema.fields.map(x => x.dataType).foreach(println(_))
    TestUtils.conditionFailTest(dft.filter("size(history) = 4").count() == 3)
    TestUtils.conditionFailTest(dft.filter("size(history_list) = 4").count() == 3)
    TestUtils.conditionFailTest(
      dft.filter(dft("name") === "rose").select("history").collect()(0)(0).toString()
        == "WrappedArray(1, 2, 5, 5)")
  }

  "postpad String" should "work properly" in {
    val data = sc.parallelize(Seq(
      Row("jack", Seq("1", "2", "3", "4", "5"), Seq(Seq("1", "2", "3"), Seq("1", "2", "3"))),
      Row("alice", Seq("4", "5", "6", "7", "8"), Seq(Seq("1", "2", "3"), Seq("1", "2", "3"))),
      Row("rose", Seq("1", "2"), Seq(Seq("1", "2", "3"), Seq("1", "2", "3"), Seq("1", "2", "3")))))
    val schema = StructType(Array(
      StructField("name", StringType, true),
      StructField("history", ArrayType(StringType), true),
      StructField("history_list", ArrayType(ArrayType(StringType)), true)
    ))
    val df = sqlContext.createDataFrame(data, schema)
    val df2 = friesian.postPad(df, Array("history", "history_list").toList.asJava, 4, "<MSK>")
    val dft = friesian.postPad(df2, Array("history", "history_list").toList.asJava, 5, 2)
    dft.show(3, false)
    dft.schema.fields.map(x => x.dataType).foreach(println(_))
    TestUtils.conditionFailTest(dft.filter("size(history) = 5").count() == 3)
    TestUtils.conditionFailTest(dft.filter("size(history_list) = 5").count() == 3)
    TestUtils.conditionFailTest(
      dft.filter(dft("name") === "rose").select("history").collect()(0)(0).toString()
        == "WrappedArray(1, 2, <MSK>, <MSK>, 2)")
  }

  "addHisSeq int and float" should "work properly" in {
    val data = sc.parallelize(Seq(
      Row("rose", "A", 1, 2.0f, "2019-07-01 12:01:19.000"),
      Row("jack", "B", 1, 2.0f, "2019-07-01 12:01:19.000"),
      Row("jack", "A", 2, 2.0f, "2019-08-01 12:01:19.000"),
      Row("jack", "C", 3, 2.0f, "2019-09-01 12:01:19.000"),
      Row("jack", "D", 4, 1.0f, "2019-10-01 12:01:19.000"),
      Row("jack", "A", 5, 1.0f, "2019-11-01 12:01:19.000"),
      Row("jack", "E", 6, 1.0f, "2019-12-01 12:01:19.000"),
      Row("jack", "F", 7, 0.0f, "2019-12-02 12:01:19.000"),
      Row("alice", "G", 4, 0.0f, "2019-09-01 12:01:19.000"),
      Row("alice", "H", 5, 1.0f, "2019-10-01 12:01:19.000"),
      Row("alice", "I", 6, 0.0f, "2019-11-01 12:01:19.000")))
    val schema = StructType(Array(
      StructField("name", StringType, true),
      StructField("category", StringType, true),
      StructField("item", IntegerType, true),
      StructField("other", FloatType, true),
      StructField("time", StringType, true)
    ))
    val df = sqlContext.createDataFrame(data, schema)
      .withColumn("ts", col("time").cast("timestamp").cast("long"))

    df.show(false)
    val dft = friesian.addHistSeq(df, Array("item", "other").toList.asJava, "name", "ts", 1, 4)
    TestUtils.conditionFailTest(dft.count() == 8)
    TestUtils.conditionFailTest(dft.filter(df("name") === "alice").count() == 2)
    TestUtils.conditionFailTest(dft.filter(df("name") === "jack").count() == 6)
    TestUtils.conditionFailTest(dft.columns.contains("item_hist_seq"))
    TestUtils.conditionFailTest(dft.columns.contains("other_hist_seq"))
  }

  "addHisSeq double long" should "work properly" in {
    val data = sc.parallelize(Seq(
      Row("rose", 1L, 2.0, "2019-07-01 12:01:19.000"),
      Row("jack", 1L, 2.0, "2019-07-01 12:01:19.000"),
      Row("jack", 2L, 2.0, "2019-08-01 12:01:19.000"),
      Row("jack", 3L, 2.0, "2019-09-01 12:01:19.000"),
      Row("jack", 4L, 1.0, "2019-10-01 12:01:19.000"),
      Row("jack", 5L, 1.0, "2019-11-01 12:01:19.000"),
      Row("jack", 6L, 1.0, "2019-12-01 12:01:19.000"),
      Row("jack", 7L, 0.0, "2019-12-02 12:01:19.000"),
      Row("alice", 4L, 0.0, "2019-09-01 12:01:19.000"),
      Row("alice", 5L, 1.0, "2019-10-01 12:01:19.000"),
      Row("alice", 6L, 0.0, "2019-11-01 12:01:19.000")))
    val schema = StructType(Array(
      StructField("name", StringType, true),
      StructField("item", LongType, true),
      StructField("other", DoubleType, true),
      StructField("time", StringType, true)
    ))
    val df = sqlContext.createDataFrame(data, schema)
      .withColumn("ts", col("time").cast("timestamp").cast("long"))

    val dft = friesian.addHistSeq(df, Array("item", "other").toList.asJava, "name", "ts", 1, 4)
    TestUtils.conditionFailTest(dft.count() == 8)
    TestUtils.conditionFailTest(dft.filter(df("name") === "alice").count() == 2)
    TestUtils.conditionFailTest(dft.filter(df("name") === "jack").count() == 6)
    TestUtils.conditionFailTest(dft.columns.contains("item_hist_seq"))
    TestUtils.conditionFailTest(dft.columns.contains("other_hist_seq"))
  }

  "addHisSeq numSeqs" should "work properly" in {
    val data = sc.parallelize(Seq(
      Row("rose", "A", 1, 2.0f, "2019-07-01 12:01:19.000"),
      Row("jack", "B", 1, 2.0f, "2019-07-01 12:01:19.000"),
      Row("jack", "A", 2, 2.0f, "2019-08-01 12:01:19.000"),
      Row("jack", "C", 3, 2.0f, "2019-09-01 12:01:19.000"),
      Row("jack", "D", 4, 1.0f, "2019-10-01 12:01:19.000"),
      Row("jack", "A", 5, 1.0f, "2019-11-01 12:01:19.000"),
      Row("jack", "E", 6, 1.0f, "2019-12-01 12:01:19.000"),
      Row("jack", "F", 7, 0.0f, "2019-12-02 12:01:19.000"),
      Row("alice", "G", 4, 0.0f, "2019-09-01 12:01:19.000"),
      Row("alice", "H", 5, 1.0f, "2019-10-01 12:01:19.000"),
      Row("alice", "I", 6, 0.0f, "2019-11-01 12:01:19.000")))
    val schema = StructType(Array(
      StructField("name", StringType, true),
      StructField("category", StringType, true),
      StructField("item", IntegerType, true),
      StructField("other", FloatType, true),
      StructField("time", StringType, true)
    ))
    val df = sqlContext.createDataFrame(data, schema)
      .withColumn("ts", col("time").cast("timestamp").cast("long"))

    val dft = friesian.addHistSeq(df, Array("item", "other").toList.asJava, "name",
      "ts", 1, 4, 1)
    TestUtils.conditionFailTest(dft.count() == 2)
    TestUtils.conditionFailTest(dft.filter(df("name") === "alice").count() == 1)
    TestUtils.conditionFailTest(dft.filter(df("name") === "jack").count() == 1)
    TestUtils.conditionFailTest(dft.columns.contains("item_hist_seq"))
    TestUtils.conditionFailTest(dft.columns.contains("other_hist_seq"))
  }

  "addNegSamples" should "work properly" in {
    val data = sc.parallelize(Seq(
      Row("jack", 1, "2019-07-01 12:01:19.000"),
      Row("jack", 2, "2019-08-01 12:01:19.000"),
      Row("jack", 3, "2019-09-01 12:01:19.000"),
      Row("alice", 4, "2019-09-01 12:01:19.000"),
      Row("alice", 5, "2019-10-01 12:01:19.000"),
      Row("alice", 6, "2019-11-01 12:01:19.000")))
    val schema = StructType(Array(
      StructField("name", StringType, true),
      StructField("item", IntegerType, true),
      StructField("time", StringType, true)
    ))
    val df = sqlContext.createDataFrame(data, schema)
    val dft = friesian.addNegSamples(df, 10, negNum = 2)
    TestUtils.conditionFailTest(dft.filter(col("label") === 1).count() == 6)
    TestUtils.conditionFailTest(dft.filter(col("label") === 0).count() == 12)
  }

  "addNegHisSeq" should "work properly" in {
    val data: RDD[Row] = sc.parallelize(Seq(
      Row("jack", Seq(1, 2, 3, 4, 5)),
      Row("alice", Seq(4, 5, 6, 7, 8)),
      Row("rose", Seq(1, 2))))

    val schema = StructType(Array(
      StructField("name", StringType, true),
      StructField("history", ArrayType(IntegerType), true)
    ))
    val df = sqlContext.createDataFrame(data, schema)
    val dft = friesian.addNegHisSeq(df, 9, "history", 4)
    TestUtils.conditionFailTest(dft.select("neg_history").collect().length == 3)
    TestUtils.conditionFailTest(dft.select("neg_history").rdd.map(r =>
      r.getAs[mutable.WrappedArray[mutable.WrappedArray[Int]]](0)).collect()(0).length == 5)
  }

  "addValueFeatures" should "work properly" in {

    val data: RDD[Row] = sc.parallelize(Seq(
      Row("jack", 2, Seq(1, 2, 3, 4, 5), Seq(Seq(1, 2, 3, 4, 5))),
      Row("alice", 3, Seq(4, 5, 6, 7, 8), Seq(Seq(1, 2, 3, 4, 5))),
      Row("rose", 4, Seq(1, 2), Seq(Seq(1, 2, 3, 4, 5)))))

    val schema: StructType = StructType(Array(
      StructField("name", StringType, true),
      StructField("item", IntegerType, true),
      StructField("item_hist_seq", ArrayType(IntegerType), true),
      StructField("nclk_item_hist_seq", ArrayType(ArrayType(IntegerType)), true)))

    val df = sqlContext.createDataFrame(data, schema)

    val mapping = Map(0 -> 0, 1 -> 0, 2 -> 0, 3 -> 0, 4 -> 1, 5 -> 1, 6 -> 1, 8 -> 2, 9 -> 2)
      .map(x => Row(x._1, x._2)).toArray

    val dictSchema: StructType = StructType(Array(
      StructField("key", IntegerType, true),
      StructField("value", IntegerType, true)))
    val dictDF = sqlContext.createDataFrame(sc.parallelize(mapping), dictSchema)

    val df1 = friesian.addValueFeatures(df,
      Array("item", "item_hist_seq", "nclk_item_hist_seq").toList.asJava,
      dictDF, "item", "category")

    TestUtils.conditionFailTest(df1.select("category").count == 3)
    TestUtils.conditionFailTest(df1.select("category_hist_seq").count == 3)
    TestUtils.conditionFailTest(df1.select("nclk_category_hist_seq").count == 3)
  }

  "Fill median" should "work properly" in {
    val path = resource.getFile + "/data1.parquet"
    val df = sqlContext.read.parquet(path)
    val cols = Array("col_1", "col_2")
    val dfFilled = friesian.fillMedian(df, cols.toList.asJava)
    TestUtils.conditionFailTest(dfFilled.filter(dfFilled("col_1").isNull).count == 0)
    TestUtils.conditionFailTest(dfFilled.filter(dfFilled("col_2").isNull).count == 0)
  }

  "Median" should "work properly" in {
    val path = resource.getFile + "/data1.parquet"
    val df = sqlContext.read.parquet(path)
    val cols = Array("col_1", "col_2")
    val dfFilled = friesian.median(df, cols.toList.asJava)
    TestUtils.conditionFailTest(dfFilled.count == 2)
    TestUtils.conditionFailTest(dfFilled.filter("column == 'col_1'")
      .filter("median == 1.0").count == 1)
  }
}

redpajama_set_name: RedPajamaGithub


text:
Q: Adding JQueryMobile Dialog functionality to PhotoSwipe footer Trying to get a jQueryMobile Dialog to open up upon the clicking of an option in a PhotoSwipe footer.
I'm using the following code:
                 options = {
                    enableMouseWheel: true,
                        enableKeyboard: true,
                        getToolbar: function(){
                            return '
Close

Play

Previous

Next
Pages';
                        }
                    };

                    myPhotoSwipe = $("#Gallery a").photoSwipe(options);

But when I click "Pages", nothing happens, Firebug is reporting that it's loading the page via JSON and not actually rendering it.
Any ideas on how to resolve this?

A: My guess is that it's being loaded underneath the Photoswipe modal. If you inspect the Photoswipe modal you'll probably see that it's z-index is set super high (500+). The jQuery Mobile dialog would have to have a higher z-index than Photoswipe for you to see it.

redpajama_set_name: RedPajamaStackExchange


Over two winters, researchers looked at the movements of grey wolves near Fort McMurray, Alta. in conjunction with data on snowfall in the area. They found the animals changed their movements on snowy days.
When snow falls, wolves chill out, according to a recent study from the University of Alberta.
Over two winters, researchers looked at the movements of grey wolves near Fort McMurray, Alta. in conjunction with data on snowfall in the area.
"We found that on the night that it was snowing, wolves rested more than they travelled, and when they travelled, they travelled slower than on other days when there wasn't any snowfall," Amanda Droghini, a former master's student with the biology department.
The researchers also found that within a day of the snowfall, the wolves returned to their normal movement behaviours. They don't know exactly why the wolves changed their movements, but they have some theories.
"We think that it might be something about actively falling snow," said Droghini.
Snow, like rain, clears the air of scent molecules, she said. Wolves rely heavily on their sense of smell to hunt, especially at night. Most of the wolves studied do their hunting after dark.
Another possible explanation, said Droghini, is that the wolves' prey move less in falling snow.
"We unfortunately don't have the data to test this," she said, but if other animals are hunkered down, waiting for the snow to stop, there is no incentive for the wolves to go out hunting.
The researchers used data from remote cameras that monitored snowfalls, and collars on 17 wolves. These wolves were also part of a separate study that looked at the movement of wolves and moose near Fort McMurray.
It's hard to say right now how climate change might affect the behaviour of wolves in snow, said Droghini.
Information about snow conditions is scarce, particularly in the North where there aren't many weather stations.
Droghini said more freeze and thaw cycles could make movement difficult for animals in winter.
Rain after snow can create an icy crust over the snowpack, and this kind of snow is the most challenging for animals to walk through, she said.
"It costs them a lot of energy."
The concern, said Droghini, is that it might be more difficult for animals to maintain the energy levels they need for the reproductive season.